git.cweiske.de
/
enigma2.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
4404768
)
more __deref__ changes
author
Andreas Monzner
<andreas.monzner@multimedia-labs.de>
Wed, 21 Mar 2007 16:30:23 +0000
(16:30 +0000)
committer
Andreas Monzner
<andreas.monzner@multimedia-labs.de>
Wed, 21 Mar 2007 16:30:23 +0000
(16:30 +0000)
lib/gui/eslider.cpp
patch
|
blob
|
history
lib/gui/eslider.h
patch
|
blob
|
history
lib/gui/ewidgetdesktop.cpp
patch
|
blob
|
history
lib/gui/ewidgetdesktop.h
patch
|
blob
|
history
lib/gui/ewindowstyleskinned.cpp
patch
|
blob
|
history
lib/gui/ewindowstyleskinned.h
patch
|
blob
|
history
lib/python/Components/Sources/RadioText.py
patch
|
blob
|
history
lib/python/Plugins/Extensions/PicturePlayer/plugin.py
patch
|
blob
|
history
skin.py
patch
|
blob
|
history
diff --git
a/lib/gui/eslider.cpp
b/lib/gui/eslider.cpp
index df199c47ddaa1fa5dfb7c4ffd5384229bf418fde..dd2aac9e73c329b9f3eb64ad73ae30c84263719b 100644
(file)
--- a/
lib/gui/eslider.cpp
+++ b/
lib/gui/eslider.cpp
@@
-5,6
+5,11
@@
eSlider::eSlider(eWidget *parent)
{
}
{
}
+void eSlider::setPixmap(ePtr<gPixmap> &pixmap)
+{
+ setPixmap(pixmap.operator->());
+}
+
void eSlider::setPixmap(gPixmap *pixmap)
{
m_pixmap = pixmap;
void eSlider::setPixmap(gPixmap *pixmap)
{
m_pixmap = pixmap;
diff --git
a/lib/gui/eslider.h
b/lib/gui/eslider.h
index 303977a2574485edcf87322a3bf01a2df38fd75f..c544072650a1ad2b1ce3ccb300536133a193f120 100644
(file)
--- a/
lib/gui/eslider.h
+++ b/
lib/gui/eslider.h
@@
-15,6
+15,7
@@
public:
void setBorderWidth(int pixel);
void setBorderColor(const gRGB &color);
void setPixmap(gPixmap *pixmap);
void setBorderWidth(int pixel);
void setBorderColor(const gRGB &color);
void setPixmap(gPixmap *pixmap);
+ void setPixmap(ePtr<gPixmap> &pixmap);
protected:
int event(int event, void *data=0, void *data2=0);
private:
protected:
int event(int event, void *data=0, void *data2=0);
private:
diff --git
a/lib/gui/ewidgetdesktop.cpp
b/lib/gui/ewidgetdesktop.cpp
index 4d0c0a9b73437cd04ee798b1892d8fa5906f018a..9e4830830e3266cc2624c73de058dfc34351a253 100644
(file)
--- a/
lib/gui/ewidgetdesktop.cpp
+++ b/
lib/gui/ewidgetdesktop.cpp
@@
-287,6
+287,11
@@
void eWidgetDesktop::setRedrawTask(eMainloop &ml)
m_timer->start(0, 1);
}
m_timer->start(0, 1);
}
+void eWidgetDesktop::makeCompatiblePixmap(ePtr<gPixmap> &pm)
+{
+ makeCompatiblePixmap(*(pm.operator->()));
+}
+
void eWidgetDesktop::makeCompatiblePixmap(gPixmap &pm)
{
if (m_comp_mode != cmImmediate)
void eWidgetDesktop::makeCompatiblePixmap(gPixmap &pm)
{
if (m_comp_mode != cmImmediate)
diff --git
a/lib/gui/ewidgetdesktop.h
b/lib/gui/ewidgetdesktop.h
index fb4b3b82b2c3a7ab7e1f207b0e52bc19f80d007f..7237df96a2107b6c3a2d1dcddb4653d6542cb8e8 100644
(file)
--- a/
lib/gui/ewidgetdesktop.h
+++ b/
lib/gui/ewidgetdesktop.h
@@
-54,7
+54,8
@@
public:
void setPalette(gPixmap &pm);
void setRedrawTask(eMainloop &ml);
void setPalette(gPixmap &pm);
void setRedrawTask(eMainloop &ml);
-
+
+ void makeCompatiblePixmap(ePtr<gPixmap> &pm);
void makeCompatiblePixmap(gPixmap &pm);
enum {
void makeCompatiblePixmap(gPixmap &pm);
enum {
diff --git
a/lib/gui/ewindowstyleskinned.cpp
b/lib/gui/ewindowstyleskinned.cpp
index 03c3fb74156b4526e4a5bad3e228d8b6758056b7..0b20c9255995a9749f60e65726bf9127cbcd9ba8 100644
(file)
--- a/
lib/gui/ewindowstyleskinned.cpp
+++ b/
lib/gui/ewindowstyleskinned.cpp
@@
-214,6
+214,11
@@
RESULT eWindowStyleSkinned::getFont(int what, ePtr<gFont> &fnt)
return 0;
}
return 0;
}
+void eWindowStyleSkinned::setPixmap(int bs, int bp, ePtr<gPixmap> &ptr)
+{
+ setPixmap(bs, bp, *(ptr.operator->()));
+}
+
void eWindowStyleSkinned::setPixmap(int bs, int bp, gPixmap &pixmap)
{
if ((bs >= bsMax) || (bs < 0))
void eWindowStyleSkinned::setPixmap(int bs, int bp, gPixmap &pixmap)
{
if ((bs >= bsMax) || (bs < 0))
diff --git
a/lib/gui/ewindowstyleskinned.h
b/lib/gui/ewindowstyleskinned.h
index 57c54a08ff704e5e8032faff22729a69bb673c21..2a30f1787785606bcd3d74993586b06e6827df83 100644
(file)
--- a/
lib/gui/ewindowstyleskinned.h
+++ b/
lib/gui/ewindowstyleskinned.h
@@
-52,6
+52,7
@@
public:
bpiBottomRight = 8,
};
bpiBottomRight = 8,
};
+ void setPixmap(int bs, int bp, ePtr<gPixmap> &pixmap);
void setPixmap(int bs, int bp, gPixmap &pixmap);
enum {
void setPixmap(int bs, int bp, gPixmap &pixmap);
enum {
diff --git
a/lib/python/Components/Sources/RadioText.py
b/lib/python/Components/Sources/RadioText.py
index de10ad8159227563f41e793d742c7daf7902edc6..21a3f1aab364228a92cfdde89ac0bec9ba025664 100644
(file)
--- a/
lib/python/Components/Sources/RadioText.py
+++ b/
lib/python/Components/Sources/RadioText.py
@@
-3,22
+3,24
@@
from Components.Element import cached
from enigma import iPlayableService
from Source import Source
from enigma import iPlayableService
from Source import Source
-class R
adioText
(PerServiceBase, Source, object):
+class R
dsDecoder
(PerServiceBase, Source, object):
def __init__(self, navcore):
Source.__init__(self)
PerServiceBase.__init__(self, navcore,
{
iPlayableService.evStart: self.gotEvent,
iPlayableService.evUpdatedRadioText: self.gotEvent,
def __init__(self, navcore):
Source.__init__(self)
PerServiceBase.__init__(self, navcore,
{
iPlayableService.evStart: self.gotEvent,
iPlayableService.evUpdatedRadioText: self.gotEvent,
+ iPlayableService.evUpdatedRtpText: self.gotEvent,
+ iPlayableService.evUpdatedRassInteractivePicMask: self.gotEvent,
iPlayableService.evEnd: self.gotEvent
}, with_event=True)
@cached
iPlayableService.evEnd: self.gotEvent
}, with_event=True)
@cached
- def get
Text
(self):
+ def get
Decoder
(self):
service = self.navcore.getCurrentService()
service = self.navcore.getCurrentService()
- return service and service.r
adioText
()
+ return service and service.r
dsDecoder
()
-
radiotext = property(getText
)
+
decoder = property(getDecoder
)
def gotEvent(self, what):
if what in [iPlayableService.evStart, iPlayableService.evEnd]:
def gotEvent(self, what):
if what in [iPlayableService.evStart, iPlayableService.evEnd]:
diff --git
a/lib/python/Plugins/Extensions/PicturePlayer/plugin.py
b/lib/python/Plugins/Extensions/PicturePlayer/plugin.py
index 34e8c10f471e017e021d224458ef6f3cce1e13d0..23c250efcdb931788ae180668b8ff9cc123c1b28 100644
(file)
--- a/
lib/python/Plugins/Extensions/PicturePlayer/plugin.py
+++ b/
lib/python/Plugins/Extensions/PicturePlayer/plugin.py
@@
-158,7
+158,7
@@
class ThumbView(Screen):
ptr = loadPic(self.path + self.thumblist[self.thumbindex], 180, 160, self.aspect, int(config.pic.resize.value), int(config.pic.rotate.value),1, cachefile)
if ptr != None:
self["thumb"+str(self.thumbindex)].show()
ptr = loadPic(self.path + self.thumblist[self.thumbindex], 180, 160, self.aspect, int(config.pic.resize.value), int(config.pic.rotate.value),1, cachefile)
if ptr != None:
self["thumb"+str(self.thumbindex)].show()
- self["thumb"+str(self.thumbindex)].instance.setPixmap(ptr
.__deref__()
)
+ self["thumb"+str(self.thumbindex)].instance.setPixmap(ptr)
self.thumbindex += 1
if self.thumbindex < 6:
self.thumbindex += 1
if self.thumbindex < 6:
@@
-297,7
+297,7
@@
class PicView(Screen):
if self.currPic != None:
self.old = self.index
self["file"].setText(self.list[self.old][0] + " (" + str(self.old+1) + "/" + str(self.maxentry+1) + ")")
if self.currPic != None:
self.old = self.index
self["file"].setText(self.list[self.old][0] + " (" + str(self.old+1) + "/" + str(self.maxentry+1) + ")")
- self["picture"].instance.setPixmap(self.currPic
.__deref__()
)
+ self["picture"].instance.setPixmap(self.currPic)
self.next()
self["point"].show()
self.next()
self["point"].show()
@@
-489,7
+489,7
@@
class picmain(Screen):
ptr = loadPic(self.filelist.getCurrentDirectory() + self.filelist.getFilename(), 180, 160, self.aspect, int(config.pic.resize.value), 0, 0, cachefile)
if ptr != None:
self["thumbnail"].show()
ptr = loadPic(self.filelist.getCurrentDirectory() + self.filelist.getFilename(), 180, 160, self.aspect, int(config.pic.resize.value), 0, 0, cachefile)
if ptr != None:
self["thumbnail"].show()
- self["thumbnail"].instance.setPixmap(ptr
.__deref__()
)
+ self["thumbnail"].instance.setPixmap(ptr)
else:
self["thumbnail"].hide()
else:
self["thumbnail"].hide()
diff --git
a/skin.py
b/skin.py
index fc4721dd69943695f7257e742bfd645cd54fbd8a..cb433269a584459d0c8d1a5ad719ca32211bd9ef 100644
(file)
--- a/
skin.py
+++ b/
skin.py
@@
-119,9
+119,8
@@
def applySingleAttribute(guiObject, desktop, attrib, value):
guiObject.setZPosition(int(value))
elif attrib == "pixmap":
ptr = loadPixmap(value) # this should already have been filename-resolved.
guiObject.setZPosition(int(value))
elif attrib == "pixmap":
ptr = loadPixmap(value) # this should already have been filename-resolved.
- # that __deref__ still scares me!
- desktop.makeCompatiblePixmap(ptr.__deref__())
- guiObject.setPixmap(ptr.__deref__())
+ desktop.makeCompatiblePixmap(ptr)
+ guiObject.setPixmap(ptr)
# guiObject.setPixmapFromFile(value)
elif attrib == "alphatest": # used by ePixmap
guiObject.setAlphatest(
# guiObject.setPixmapFromFile(value)
elif attrib == "alphatest": # used by ePixmap
guiObject.setAlphatest(
@@
-189,8
+188,8
@@
def applySingleAttribute(guiObject, desktop, attrib, value):
(name, pos) = value.split(':')
pos = parsePosition(pos)
ptr = loadPixmap(name)
(name, pos) = value.split(':')
pos = parsePosition(pos)
ptr = loadPixmap(name)
- desktop.makeCompatiblePixmap(ptr
.__deref__()
)
- guiObject.setPointer({"pointer": 0, "seek_pointer": 1}[attrib], ptr
.__deref__()
, pos)
+ desktop.makeCompatiblePixmap(ptr)
+ guiObject.setPointer({"pointer": 0, "seek_pointer": 1}[attrib], ptr, pos)
elif attrib == 'shadowOffset':
guiObject.setShadowOffset(parsePosition(value))
elif attrib == 'noWrap':
elif attrib == 'shadowOffset':
guiObject.setShadowOffset(parsePosition(value))
elif attrib == 'noWrap':
@@
-253,8
+252,8
@@
def loadSingleSkinData(desktop, dom_skin, path_prefix):
png = loadPixmap(resolveFilename(SCOPE_SKIN_IMAGE, filename, path_prefix=path_prefix))
# adapt palette
png = loadPixmap(resolveFilename(SCOPE_SKIN_IMAGE, filename, path_prefix=path_prefix))
# adapt palette
- desktop.makeCompatiblePixmap(png
.__deref__()
)
- style.setPixmap(eWindowStyleSkinned.__dict__[bsName], eWindowStyleSkinned.__dict__[bpName], png
.__deref__()
)
+ desktop.makeCompatiblePixmap(png)
+ style.setPixmap(eWindowStyleSkinned.__dict__[bsName], eWindowStyleSkinned.__dict__[bpName], png)
for color in elementsWithTag(windowstyle.childNodes, "color"):
type = str(color.getAttribute("name"))
for color in elementsWithTag(windowstyle.childNodes, "color"):
type = str(color.getAttribute("name"))