|
|
2010-06-26
, 16:04
|
|
|
Posts: 2,473 |
Thanked: 12,265 times |
Joined on Oct 2009
@ Jerusalem, PS/IL
|
#11
|
|
|
2010-06-26
, 16:25
|
|
|
Posts: 2,473 |
Thanked: 12,265 times |
Joined on Oct 2009
@ Jerusalem, PS/IL
|
#12
|
#! /bin/sh -e
Q=`run-standalone.sh zenity --question --text="Install custom transitions?" --ok-label=Yes; echo $?`
if [ "$Q" = "0" ]; then
# install the custom things
echo "User chose yes"
else
# do not install the custom things
echo "User chose no"
fi
| The Following User Says Thank You to MohammadAG For This Useful Post: | ||
|
|
2010-06-26
, 16:47
|
|
|
Posts: 2,154 |
Thanked: 2,186 times |
Joined on Dec 2009
@ Hellsinki, Finland
|
#13
|
Right, try this.
Haven't tested the script cause I'm not on Maemo (on Ubuntu atm) on the N900, but it works on my PCCode:#! /bin/sh -e Q=`run-standalone.sh zenity --question --text="Install custom transitions?" --ok-label=Yes; echo $?` if [ "$Q" = "0" ]; then # install the custom things echo "User chose yes" else # do not install the custom things echo "User chose no" fi
Hope it works

| The Following User Says Thank You to d-iivil For This Useful Post: | ||
|
|
2010-06-27
, 18:07
|
|
|
Posts: 2,154 |
Thanked: 2,186 times |
Joined on Dec 2009
@ Hellsinki, Finland
|
#14
|

#! /bin/sh -e
THEMEDIR='/usr/share/themes/blackplastictheme-themedir'
if [ ! -d $THEMEDIR ]; then
exit 0
fi
rm -rf /usr/share/themes/blackplastictheme-themedir/gtk-2.0/*.cache
if [ "`readlink /etc/hildon/theme`" = /usr/share/themes/blackplastictheme-themedir ]; then
if [ -x /usr/bin/personalisation ]; then
/usr/bin/personalisation /usr/share/themes/default
fi
fi
Q=`run-standalone.sh zenity --question --text="Enable customized transitions?\n(affects only the Black Plastic theme)\n\nNote: tap outside this window to NOT to enable the transitions\n\n(choose Yes if you don't know what to do)" --ok-label=Yes; echo $?`
if [ "$Q" = "0" ]; then
# install the custom things
cp -rf /usr/share/themes/blackplastictheme-themedir/transitions.tmp /usr/share/themes/blackplastictheme-themedir/transitions.ini
else
rm -rf /usr/share/themes/blackplastictheme-themedir/transitions.ini
fi
Q2=`run-standalone.sh zenity --list --text "Choose color scheme" --radiolist --column "Pick" --column "Scheme" TRUE Black FALSE Blue FALSE Orange FALSE Pink; echo $ans`
if [ "$Q2" = "Black" ]; then
cp -rf /usr/share/themes/blackplastictheme-themedir/variations/black/* /usr/share/themes/blackplastictheme-themedir/
elif [ "$Q2" = "Blue" ]; then
cp -rf /usr/share/themes/blackplastictheme-themedir/variations/blue/* /usr/share/themes/blackplastictheme-themedir/
elif [ "$Q2" = "Orange" ]; then
cp -rf /usr/share/themes/blackplastictheme-themedir/variations/orange/* /usr/share/themes/blackplastictheme-themedir/
elif [ "$Q2" = "Pink" ]; then
cp -rf /usr/share/themes/blackplastictheme-themedir/variations/pink/* /usr/share/themes/blackplastictheme-themedir/
fi
hildon-theme-cacher $THEMEDIR
Q3=`run-standalone.sh zenity --info --text="Done! Remember to do a reboot after you have selected Black Plastic Theme to use."`
exit 0