OpenBricks / openbricks

Embedded Linux Framework
http://www.geexbox.org/
GNU General Public License v2.0
83 stars 42 forks source link

remove Custom Shutdown Timer on cuboxi and Raspberry Pi #42

Closed HolgerJeromin closed 9 years ago

HolgerJeromin commented 9 years ago

On my cuboxi i see "sleep timer" as an option in the power off menu. As this box is not designed to be powered off , we could hide the option at least on cuboxi and Raspberry Pi.

warped-rudi commented 9 years ago

This option is controlled by both the system capabilities and the skin. It will disappear if we say that the system is not capable of powering off. While this is actually true, the problem is that when doing so we also loose the ability to shutdown cleanly because "Power off System" will vanish as well.

We can avoid this by disabling the option in the skin. But that means that it only works for skins that have been patched. I do not really see a generic solution for this. However, I've added a patch (c59c11a9b7bcbcd1e52fd414af60a43ab0b5b8d3) to the confluence skin we provide:

--- a/addons/skin.confluence/720p/DialogButtonMenu.xml  2015-01-10 11:17:01.311541785 +0100
+++ b/addons/skin.confluence/720p/DialogButtonMenu.xml  2015-01-10 11:31:36.731555411 +0100
@@ -117,6 +117,7 @@
                <pulseonselect>no</pulseonselect>
                <font>font13</font>
                <label>20150</label>
+               <visible>false</visible>
                <visible>!System.HasAlarm(shutdowntimer)</visible>
                <visible>System.CanPowerDown | System.CanSuspend | System.CanHibernate</visible>
            </control>

For other skins you have to do it yourself...

HolgerJeromin commented 9 years ago

Ah, OK. Thanks for the fix. Perhaps we should report it to upstream of kodi?