- sdl is now default output
[enigma2.git] / lib / gui / epixmap.cpp
index a0655aa9df8c0a873cac8bde5b65e01c396c00c9..797c675991f60ad4fc26d7169d11300cd2bd5bbf 100644 (file)
@@ -1,4 +1,6 @@
 #include <lib/gui/epixmap.h>
+#include <lib/gdi/epng.h>
+#include <lib/gui/ewidgetdesktop.h>
 
 ePixmap::ePixmap(eWidget *parent): eWidget(parent)
 {
@@ -10,6 +12,15 @@ void ePixmap::setPixmap(gPixmap *pixmap)
        event(evtChangedPixmap);
 }
 
+void ePixmap::setPixmapFromFile(const char *filename)
+{
+       loadPNG(m_pixmap, filename);
+       
+               // TODO
+       getDesktop()->makeCompatiblePixmap(*m_pixmap);
+       event(evtChangedPixmap);
+}
+
 int ePixmap::event(int event, void *data, void *data2)
 {
        switch (event)