mirror of
https://github.com/clockworkpi/launcher_deot.git
synced 2025-12-14 16:38:53 +01:00
commit
98b0ef91e8
@ -1,6 +1,7 @@
|
|||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
|
|
||||||
import pygame
|
import pygame
|
||||||
|
import subprocess
|
||||||
|
|
||||||
#UI lib
|
#UI lib
|
||||||
from UI.constants import RUNSYS
|
from UI.constants import RUNSYS
|
||||||
@ -13,7 +14,17 @@ import config
|
|||||||
|
|
||||||
class PowerOffConfirmPage(ConfirmPage):
|
class PowerOffConfirmPage(ConfirmPage):
|
||||||
|
|
||||||
_ConfirmText = MyLangManager.Tr("Confirm Power OFF?")
|
_ConfirmText = MyLangManager.Tr("Awaiting Input")
|
||||||
|
#_FootMsg = ["Nav","Suspend","Reboot","Cancel","Shutdown"]
|
||||||
|
_FootMsg = ["Nav","","Reboot","Cancel","Shutdown"]
|
||||||
|
|
||||||
|
# uname -r
|
||||||
|
st = subprocess.check_output(["uname","-r"])
|
||||||
|
st = st.strip("\n")
|
||||||
|
st = st.strip("\t")
|
||||||
|
|
||||||
|
if "5.7" in st:
|
||||||
|
_FootMsg[1] = "Sleep"
|
||||||
|
|
||||||
def CheckBattery(self):
|
def CheckBattery(self):
|
||||||
try:
|
try:
|
||||||
@ -43,7 +54,6 @@ class PowerOffConfirmPage(ConfirmPage):
|
|||||||
def KeyDown(self,event):
|
def KeyDown(self,event):
|
||||||
|
|
||||||
if IsKeyMenuOrB(event.key):
|
if IsKeyMenuOrB(event.key):
|
||||||
|
|
||||||
self.ReturnToUpLevelPage()
|
self.ReturnToUpLevelPage()
|
||||||
self._Screen.Draw()
|
self._Screen.Draw()
|
||||||
self._Screen.SwapAndShow()
|
self._Screen.SwapAndShow()
|
||||||
@ -61,7 +71,18 @@ class PowerOffConfirmPage(ConfirmPage):
|
|||||||
cmdpath += "sudo halt -p"
|
cmdpath += "sudo halt -p"
|
||||||
pygame.event.post( pygame.event.Event(RUNSYS, message=cmdpath))
|
pygame.event.post( pygame.event.Event(RUNSYS, message=cmdpath))
|
||||||
|
|
||||||
|
if event.key == CurKeys["X"]:
|
||||||
|
cmdpath = "feh --bg-center %s;" % MySkinManager.GiveWallpaper("seeyou.png")
|
||||||
|
cmdpath += "sleep 3;"
|
||||||
|
cmdpath += "sudo reboot"
|
||||||
|
pygame.event.post( pygame.event.Event(RUNSYS, message=cmdpath))
|
||||||
|
|
||||||
|
if event.key == CurKeys["Y"]:
|
||||||
|
if self._FootMsg[1] != "":
|
||||||
|
cmdpath = "feh --bg-center %s;" % MySkinManager.GiveWallpaper("seeyou.png")
|
||||||
|
cmdpath += "sleep 3;"
|
||||||
|
cmdpath += "sudo pm-suspend"
|
||||||
|
pygame.event.post( pygame.event.Event(RUNSYS, message=cmdpath))
|
||||||
|
|
||||||
class APIOBJ(object):
|
class APIOBJ(object):
|
||||||
|
|
||||||
@ -87,4 +108,3 @@ def Init(main_screen):
|
|||||||
OBJ.Init(main_screen)
|
OBJ.Init(main_screen)
|
||||||
def API(main_screen):
|
def API(main_screen):
|
||||||
OBJ.API(main_screen)
|
OBJ.API(main_screen)
|
||||||
|
|
||||||
|
|||||||
@ -9,5 +9,5 @@ def InitSoundPage(main_screen):
|
|||||||
myvars.SoundPage = SoundPage()
|
myvars.SoundPage = SoundPage()
|
||||||
|
|
||||||
myvars.SoundPage._Screen = main_screen
|
myvars.SoundPage._Screen = main_screen
|
||||||
myvars.SoundPage._Name = "Sound volume"
|
myvars.SoundPage._Name = "Sound Volume"
|
||||||
myvars.SoundPage.Init()
|
myvars.SoundPage.Init()
|
||||||
|
|||||||
@ -27,7 +27,7 @@ class ListPage(Page):
|
|||||||
|
|
||||||
_FootMsg = ["Nav","","","Back","Enter"]
|
_FootMsg = ["Nav","","","Back","Enter"]
|
||||||
_MyList = []
|
_MyList = []
|
||||||
_ListFontObj = MyLangManager.TrFont("varela15")
|
_ListFontObj = MyLangManager.TrFont("Eurostile15")
|
||||||
|
|
||||||
_Scroller = None
|
_Scroller = None
|
||||||
|
|
||||||
|
|||||||
3
load.sh
3
load.sh
@ -7,4 +7,7 @@ cd $BASENAME/sys.py
|
|||||||
# boot sound
|
# boot sound
|
||||||
nohup mplayer -volume 75 /home/cpi/music/startup.mp3
|
nohup mplayer -volume 75 /home/cpi/music/startup.mp3
|
||||||
|
|
||||||
|
# set system volume
|
||||||
|
amixer sset 'Master' 50%
|
||||||
|
|
||||||
python run.py
|
python run.py
|
||||||
|
|||||||
@ -239,7 +239,7 @@ class FavListPage(Page):
|
|||||||
bgpng._ImgSurf = MyIconPool.GiveIconSurface("star")
|
bgpng._ImgSurf = MyIconPool.GiveIconSurface("star")
|
||||||
bgpng._MyType = ICON_TYPES["STAT"]
|
bgpng._MyType = ICON_TYPES["STAT"]
|
||||||
bgpng._Parent = self
|
bgpng._Parent = self
|
||||||
bgpng.AddLabel(MyLangManager.Tr("MyFavGames"), MyLangManager.TrFont("varela18"))
|
bgpng.AddLabel(MyLangManager.Tr("MyFavGames"), MyLangManager.TrFont("Eurostile18"))
|
||||||
bgpng.SetLableColor(MySkinManager.GiveColor('Disabled'))
|
bgpng.SetLableColor(MySkinManager.GiveColor('Disabled'))
|
||||||
bgpng.Adjust(0,0,self._BGwidth,self._BGheight,0)
|
bgpng.Adjust(0,0,self._BGwidth,self._BGheight,0)
|
||||||
|
|
||||||
|
|||||||
@ -62,7 +62,7 @@ class ListItem(object):
|
|||||||
|
|
||||||
def Init(self,text):
|
def Init(self,text):
|
||||||
|
|
||||||
#self._Fonts["normal"] = fonts["veramono12"]
|
#self._Fonts["normal"] = fonts["Eurostile12"]
|
||||||
|
|
||||||
l = Label()
|
l = Label()
|
||||||
l._PosX = 20
|
l._PosX = 20
|
||||||
@ -113,5 +113,3 @@ class ListItem(object):
|
|||||||
self._Parent._Icons["sys"].Draw()
|
self._Parent._Icons["sys"].Draw()
|
||||||
|
|
||||||
pygame.draw.line(self._Parent._CanvasHWND,MySkinManager.GiveColor('Line'),(self._PosX,self._PosY+self._Height-1),(self._PosX+self._Width,self._PosY+self._Height-1),1)
|
pygame.draw.line(self._Parent._CanvasHWND,MySkinManager.GiveColor('Line'),(self._PosX,self._PosY+self._Height-1),(self._PosX+self._Width,self._PosY+self._Height-1),1)
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -273,7 +273,7 @@ class RomListPage(Page):
|
|||||||
bgpng._ImgSurf = MyIconPool.GiveIconSurface("empty")
|
bgpng._ImgSurf = MyIconPool.GiveIconSurface("empty")
|
||||||
bgpng._MyType = ICON_TYPES["STAT"]
|
bgpng._MyType = ICON_TYPES["STAT"]
|
||||||
bgpng._Parent = self
|
bgpng._Parent = self
|
||||||
bgpng.AddLabel(MyLangManager.Tr("Please upload data over Wi-Fi"), MyLangManager.TrFont("varela22"))
|
bgpng.AddLabel(MyLangManager.Tr("Please upload data over Wi-Fi"), MyLangManager.TrFont("Eurostile22"))
|
||||||
bgpng.SetLableColor(MySkinManager.GiveColor('Disabled'))
|
bgpng.SetLableColor(MySkinManager.GiveColor('Disabled'))
|
||||||
bgpng.Adjust(0,0,self._BGwidth,self._BGheight,0)
|
bgpng.Adjust(0,0,self._BGwidth,self._BGheight,0)
|
||||||
|
|
||||||
|
|||||||
@ -21,7 +21,7 @@ from UI.lang_manager import MyLangManager
|
|||||||
import config
|
import config
|
||||||
|
|
||||||
class RomSoConfirmPage(ConfirmPage):
|
class RomSoConfirmPage(ConfirmPage):
|
||||||
_ListFont = MyLangManager.TrFont("veramono18")
|
_ListFont = MyLangManager.TrFont("Eurostile15")
|
||||||
|
|
||||||
_ConfirmText = MyLangManager.Tr("SetupGameEngineAutoQ")
|
_ConfirmText = MyLangManager.Tr("SetupGameEngineAutoQ")
|
||||||
|
|
||||||
|
|||||||
@ -17,7 +17,7 @@ MPD_socket = "/tmp/mpd.socket"
|
|||||||
#UPDATE_URL="https://raw.githubusercontent.com/clockworkpi/CPI_DEOT/master/version.json"
|
#UPDATE_URL="https://raw.githubusercontent.com/clockworkpi/CPI_DEOT/master/version.json"
|
||||||
UPDATE_URL="https://raw.githubusercontent.com/hi80482/launcher_deot/master/version.json"
|
UPDATE_URL="https://raw.githubusercontent.com/hi80482/launcher_deot/master/version.json"
|
||||||
|
|
||||||
VERSION="D.E.O.T. v2+ 200626"
|
VERSION="D.E.O.T. v2+ 200903"
|
||||||
|
|
||||||
SKIN=None
|
SKIN=None
|
||||||
|
|
||||||
|
|||||||
@ -101,10 +101,6 @@ Forget=略過
|
|||||||
Forgeting=略過此裝置...
|
Forgeting=略過此裝置...
|
||||||
Device paired=裝置已配對
|
Device paired=裝置已配對
|
||||||
|
|
||||||
#音量
|
|
||||||
Sound Volume=音量
|
|
||||||
Sound volume=音量
|
|
||||||
|
|
||||||
#背光亮度
|
#背光亮度
|
||||||
Brightness=背光亮度
|
Brightness=背光亮度
|
||||||
|
|
||||||
|
|||||||
@ -1,4 +1,4 @@
|
|||||||
{
|
{
|
||||||
"gitversion":"d89f523",
|
"gitversion":"bb15dce",
|
||||||
"version":"200626"
|
"version":"200903"
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user