Thread: Odds and ends
View Single Post
Addison's Avatar
Posts: 3,811 | Thanked: 1,151 times | Joined on Oct 2007 @ East Lansing, MI
#234
I think that I'm restoring the brightness settings too quickly after restarting MCE since the last 4 commands in the following script aren't taking.

How can I pause it for a moment so this doesn't happened?

I've tried this but I'm getting a "/usr/bin/on: line 5: wait: pid 4 is not a child of this shell" error.



blank=`gconftool-2 -g /system/osso/dsm/display/display_blank_timeout`
gconftool-2 --type int --set /apps/modest/update_interval 1
gconftool-2 --type boolean --set /apps/modest/auto_update True
sudo /etc/init.d/mce restart
wait 4
/usr/bin/set-backlight `gconftool-2 --get /apps/adv-backlight/brightness`
restore_value()
{
gconftool-2 --type $1 --set $2 `gconftool-2 --get $2`
}
gconftool-2 --type int --set /apps/osso/applet/osso-applet-display/turn_off_display 30
gconftool-2 --type int --set /apps/osso/applet/osso-applet-display/brightness_period 30
gconftool-2 --type int --set /system/osso/dsm/display/display_dim_timeout 30
gconftool-2 --type int --set /system/osso/dsm/display/display_blank_timeout 30