git.cweiske.de
/
enigma2.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
- start working on compositing support
[enigma2.git]
/
mytest.py
diff --git
a/mytest.py
b/mytest.py
index 461fdfa2593c7f90c19f71f30f09cc61844d68f5..68d777a9ee562cacf961ff07e344dbaf89dc439a 100644
(file)
--- a/
mytest.py
+++ b/
mytest.py
@@
-10,7
+10,8
@@
import ServiceReference
from Navigation import Navigation
from Navigation import Navigation
-from skin import applyGUIskin
+from skin import readSkin, applyAllAttributes
+
# A screen is a function which instanciates all components of a screen into a temporary component.
# Thus, the global stuff is a screen, too.
# A screen is a function which instanciates all components of a screen into a temporary component.
# Thus, the global stuff is a screen, too.
@@
-54,8
+55,8
@@
html = HTMLOutputDevice()
class GUIOutputDevice(OutputDevice):
parent = None
class GUIOutputDevice(OutputDevice):
parent = None
- def create(self, comp):
- comp.createGUIScreen(self.parent)
+ def create(self, comp
, desktop
):
+ comp.createGUIScreen(self.parent
, desktop
)
class Session:
def __init__(self):
class Session:
def __init__(self):
@@
-75,7
+76,7
@@
class Session:
print sys.getrefcount(self.currentDialog)
del self.currentDialog.instance
print sys.getrefcount(self.currentDialog)
del self.currentDialog.instance
-
dump(self.currentDialog)
+
#
dump(self.currentDialog)
del self.currentDialog
self.popCurrent()
del self.currentDialog
self.popCurrent()
@@
-93,16
+94,20
@@
class Session:
return screen(self, *arguments)
def instantiateDialog(self, screen, *arguments):
return screen(self, *arguments)
def instantiateDialog(self, screen, *arguments):
+ # create dialog
dlg = self.create(screen, arguments)
dlg = self.create(screen, arguments)
+
+ # read skin data
+ readSkin(dlg, None, dlg.skinName, self.desktop)
+
+ # create GUI view of this dialog
assert self.desktop != None
dlg.instance = eWindow(self.desktop)
assert self.desktop != None
dlg.instance = eWindow(self.desktop)
-
+ applyAllAttributes(dlg.instance, self.desktop, dlg.skinAttributes)
gui = GUIOutputDevice()
gui.parent = dlg.instance
gui = GUIOutputDevice()
gui.parent = dlg.instance
- gui.create(dlg)
-
- applyGUIskin(dlg, None, dlg.skinName, self.desktop)
-
+ gui.create(dlg, self.desktop)
+
return dlg
def pushCurrent(self):
return dlg
def pushCurrent(self):
@@
-153,7
+158,10
@@
def runScreenTest():
import keymapparser
keymapparser.readKeymap()
import skin
import keymapparser
keymapparser.readKeymap()
import skin
-skin.loadSkin()
+skin.loadSkin(getDesktop())
+
+import Components.InputDevice
+Components.InputDevice.InitInputDevices()
# first, setup a screen
runScreenTest()
# first, setup a screen
runScreenTest()