1 #include <lib/gui/epixmap.h>
2 #include <lib/gdi/epng.h>
3 #include <lib/gui/ewidgetdesktop.h>
5 ePixmap::ePixmap(eWidget *parent): eWidget(parent)
9 void ePixmap::setPixmap(gPixmap *pixmap)
12 event(evtChangedPixmap);
15 void ePixmap::setPixmapFromFile(const char *filename)
17 loadPNG(m_pixmap, filename);
20 getDesktop()->makeCompatiblePixmap(*m_pixmap);
21 event(evtChangedPixmap);
24 int ePixmap::event(int event, void *data, void *data2)
30 ePtr<eWindowStyle> style;
34 // eWidget::event(event, data, data2);
36 gPainter &painter = *(gPainter*)data2;
38 painter.blit(m_pixmap, ePoint(0, 0));
42 case evtChangedPixmap:
46 return eWidget::event(event, data, data2);