t = time.localtime()
timestr = "%2d:%02d:%02d" % (t.tm_hour, t.tm_min, t.tm_sec)
self.setText(timestr)
- setLCDClock(timestr)
# realisierung als GUI
def createWidget(self, parent):
-from PerServiceDisplay import *
-
-#from enigma import iPlayableService, iServiceInformationPtr
-from enigma import *
-
-class ServiceName(PerServiceDisplay):
- def __init__(self, navcore):
- PerServiceDisplay.__init__(self, navcore,
- {
- iPlayableService.evStart: self.newService,
- iPlayableService.evEnd: self.stopEvent
- })
- self.newService()
-
- def newService(self):
- service = self.navcore.getCurrentService()
-
- if service is not None:
- info = service.info()
- if info is not None:
- name = info.getName()
- self.setText(name)
- setLCD(name)
-
- def stopEvent(self):
- self.setText("");
-
extern void runMainloop();
extern void quitMainloop(int exit_code);
-extern void setLCD(const char *c);
-extern void setLCDClock(const char *c);
extern eApplication *getApplication();
extern PSignal1<void,int> &keyPressedSignal();
void runMainloop();
void quitMainloop(int exit_code);
-void setLCD(const char*);
-void setLCDClock(const char*);
eApplication *getApplication();
%immutable keyPressed;
PSignal1<void,int> &keyPressedSignal();