~# cat /home/user/.local/share/data/toggle-lpm/toggle-lpm.sh #!/bin/sh # Toggle Low Power Mode (Standby Screen) by thedead1440 STATUS=$(gconftool --get /system/osso/dsm/display/use_low_power_mode) if [ $STATUS == "true" ] then gconftool -s --type=bool /system/osso/dsm/display/use_low_power_mode false sed -i 's/toggle\-lpm\-on/toggle\-lpm\-off/' /home/user/.local/share/applications/toggle-lpm.desktop dbus-send --print-reply --dest=com.meego.core.MNotificationManager /notificationmanager com.meego.core.MNotificationManager.addNotification uint32:0 uint32:0 string:'device' string:'' string:"Standy Screen Off" string:'' string:"/home/user/.local/share/icons/hicolor/apps/toggle-lpm-off.png" uint32:0 else gconftool -s --type=bool /system/osso/dsm/display/use_low_power_mode true sed -i 's/toggle\-lpm\-off/toggle\-lpm\-on/' /home/user/.local/share/applications/toggle-lpm.desktop dbus-send --print-reply --dest=com.meego.core.MNotificationManager /notificationmanager com.meego.core.MNotificationManager.addNotification uint32:0 uint32:0 string:'device' string:'' string:"Standy Screen On" string:'' string:"/home/user/.local/share/icons/hicolor/apps/toggle-lpm-on.png" uint32:0 fi
~# cat /home/user/.local/share/applications/toggle-lpm.desktop [Desktop Entry] Encoding=UTF-8 Version=1.0 Type=Application Terminal=false Name=Toggle LPM Exec=/bin/sh /home/user/.local/share/data/toggle-lpm/toggle-lpm.sh Icon=/home/user/.local/share/icons/hicolor/apps/toggle-lpm-on.png X-Window-Icon= X-HildonDesk-ShowInToolbar=true X-Osso-Type=application/x-executable
#!/bin/sh # Toggle WLAN by thedead1440 STATUS=$(/sbin/mcetool --status | grep -v grep | grep WLAN | awk '{print $2}' | head -1) if [ $STATUS == "enabled" ] then dbus-send --print-reply --dest=com.meego.core.MNotificationManager /notificationmanager com.meego.core.MNotificationManager.addNotification uint32:0 uint32:0 string:'device' string:'' string:"WLAN Off" string:'' string:"/home/user/.local/share/icons/hicolor/apps/toggle-wlan-off.png" uint32:0 sed -i 's/toggle\-wlan\-on/toggle\-wlan\-off/' /home/user/.local/share/applications/toggle-wlan.desktop gconftool -s --type=bool /system/osso/connectivity/network_type/restricted_mode true `/sbin/mcetool --disable-radio=wlan` else dbus-send --print-reply --dest=com.meego.core.MNotificationManager /notificationmanager com.meego.core.MNotificationManager.addNotification uint32:0 uint32:0 string:'device' string:'' string:"WLAN On" string:'' string:"/home/user/.local/share/icons/hicolor/apps/toggle-wlan-on.png" uint32:0 sed -i 's/toggle\-wlan\-off/toggle\-wlan\-on/' /home/user/.local/share/applications/toggle-wlan.desktop gconftool -s --type=bool /system/osso/connectivity/network_type/restricted_mode false `/sbin/mcetool --enable-radio=wlan` fi
#!/bin/sh # Toggle WLAN by thedead1440 STATUS=$(/sbin/mcetool --status | grep -v grep | grep WLAN | awk '{print $2}' | head -1) if [ $STATUS == "enabled" ] then sed -i 's/toggle\-wlan\-on/toggle\-wlan\-off/' /home/user/.local/share/applications/toggle-wlan.desktop gconftool -s --type=bool /system/osso/connectivity/network_type/restricted_mode true `/sbin/mcetool --disable-radio=wlan` else sed -i 's/toggle\-wlan\-off/toggle\-wlan\-on/' /home/user/.local/share/applications/toggle-wlan.desktop gconftool -s --type=bool /system/osso/connectivity/network_type/restricted_mode false `/sbin/mcetool --enable-radio=wlan` fi
[Desktop Entry] Encoding=UTF-8 Version=1.0 Type=Application Terminal=false Name=Toggle WLAN Exec=/bin/sh /home/user/.local/share/data/toggle-wlan/toggle-wlan.sh Icon=/home/user/.local/share/icons/hicolor/apps/toggle-wlan-on.png X-Window-Icon= X-HildonDesk-ShowInToolbar=true X-Osso-Type=application/x-executable Name[en_SG]=toggle-wlan.desktop