Browse Source

Update __init__.py

This change adds the option to reboot with the "X" button
QuantumKraken 5 years ago
parent
commit
200339dddb
1 changed files with 6 additions and 2 deletions
  1. 6 2
      Menu/GameShell/PowerOFF/__init__.py

+ 6 - 2
Menu/GameShell/PowerOFF/__init__.py

@@ -11,8 +11,8 @@ import config
 
 class PowerOffConfirmPage(ConfirmPage):
     
-    _ConfirmText = "Confirm Power OFF?"
-    
+    _ConfirmText = "Awaiting Input?"
+    _FootMsg = ["Nav","Reboot","","Cancel","Shutdown"]
 
     def CheckBattery(self):
         try:
@@ -59,7 +59,11 @@ class PowerOffConfirmPage(ConfirmPage):
             
             cmdpath += "sudo halt -p"
             pygame.event.post( pygame.event.Event(RUNSYS, message=cmdpath))
+            
+        if event.key == CurKeys["X"]:
 
+            cmdpath = "sudo reboot"
+            pygame.event.post( pygame.event.Event(RUNSYS, message=cmdpath))
 
 
 class APIOBJ(object):