mirror of
https://github.com/clockworkpi/launcher.git
synced 2025-12-13 10:18:51 +01:00
commit
069157725c
@ -95,10 +95,16 @@ class AboutPage(Page):
|
|||||||
self._Icons = {}
|
self._Icons = {}
|
||||||
|
|
||||||
def CpuMhz(self):
|
def CpuMhz(self):
|
||||||
|
|
||||||
|
try:
|
||||||
with open("/sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq") as f:
|
with open("/sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq") as f:
|
||||||
content = f.readlines()
|
content = f.readlines()
|
||||||
content = [x.strip() for x in content]
|
content = [x.strip() for x in content]
|
||||||
|
|
||||||
|
except:
|
||||||
|
print("open %s failed" % "/sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq")
|
||||||
|
content = ["0"]
|
||||||
|
|
||||||
mhz = int(content[0]) / 1000.0
|
mhz = int(content[0]) / 1000.0
|
||||||
|
|
||||||
cpuscalemhz = {}
|
cpuscalemhz = {}
|
||||||
|
|||||||
@ -9,6 +9,7 @@ from UI.label import Label
|
|||||||
from UI.fonts import fonts
|
from UI.fonts import fonts
|
||||||
from UI.icon_item import IconItem
|
from UI.icon_item import IconItem
|
||||||
from UI.icon_pool import MyIconPool
|
from UI.icon_pool import MyIconPool
|
||||||
|
from UI.keys_def import CurKeys
|
||||||
|
|
||||||
from libs.DBUS import is_wifi_connected_now,get_wifi_ip
|
from libs.DBUS import is_wifi_connected_now,get_wifi_ip
|
||||||
|
|
||||||
@ -161,6 +162,13 @@ class TinyCloudPage(Page):
|
|||||||
|
|
||||||
self.SetLabels()
|
self.SetLabels()
|
||||||
|
|
||||||
|
def KeyDown(self,event):
|
||||||
|
if event.key == CurKeys["A"] or event.key == CurKeys["Menu"]:
|
||||||
|
if self._FootMsg[3] == "Back":
|
||||||
|
self.ReturnToUpLevelPage()
|
||||||
|
self._Screen.Draw()
|
||||||
|
self._Screen.SwapAndShow()
|
||||||
|
return
|
||||||
|
|
||||||
def Draw(self):
|
def Draw(self):
|
||||||
if self._DrawOnce == False:
|
if self._DrawOnce == False:
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user