aboutsummaryrefslogtreecommitdiff
path: root/skin.py
diff options
context:
space:
mode:
authorFelix Domke <tmbinc@elitedvb.net>2005-05-20 20:50:42 +0000
committerFelix Domke <tmbinc@elitedvb.net>2005-05-20 20:50:42 +0000
commit5610b97e30804e35cc242e14702e4f4cb8f5aa40 (patch)
treeee64ee0c80bed5baa6792a88d6ae8fdd22b9152b /skin.py
parent8eb03b9a607269d101bf67c7734cf3fb5346ccf5 (diff)
downloadenigma2-5610b97e30804e35cc242e14702e4f4cb8f5aa40.tar.gz
enigma2-5610b97e30804e35cc242e14702e4f4cb8f5aa40.zip
- merge cluts for borders, too
Diffstat (limited to 'skin.py')
-rw-r--r--skin.py9
1 files changed, 6 insertions, 3 deletions
diff --git a/skin.py b/skin.py
index 3f5cd26e..bc4931fb 100644
--- a/skin.py
+++ b/skin.py
@@ -162,7 +162,6 @@ def applyAttributes(guiObject, node, desktop):
raise "loading PNG failed!"
x = ptr
ptr = ptr.__deref__()
- print desktop
desktop.makeCompatiblePixmap(ptr)
guiObject.setPixmap(ptr)
# guiObject.setPixmapFromFile(value)
@@ -200,7 +199,7 @@ def applyAttributes(guiObject, node, desktop):
except AttributeError:
print "widget %s (%s) doesn't support attribute %s!" % ("", guiObject.__class__.__name__, attrib)
-def loadSkin():
+def loadSkin(desktop):
print "loading skin..."
def getPNG(x):
@@ -231,7 +230,11 @@ def loadSkin():
bpName = str(pixmap.getAttribute("pos"))
filename = str(pixmap.getAttribute("filename"))
- style.setPixmap(eWindowStyleSkinned.__dict__[bsName], eWindowStyleSkinned.__dict__[bpName], getPNG(filename))
+ png = getPNG(filename)
+
+ # adapt palette
+ desktop.makeCompatiblePixmap(png)
+ style.setPixmap(eWindowStyleSkinned.__dict__[bsName], eWindowStyleSkinned.__dict__[bpName], png)
for color in elementsWithTag(windowstyle.childNodes, "color"):
type = str(color.getAttribute("name"))