-rw-r--r-- | examples/menuapplet/config.in | 2 | ||||
-rw-r--r-- | examples/menuapplet/example.cpp | 9 | ||||
-rw-r--r-- | examples/menuapplet/menuapplet.pro | 2 |
3 files changed, 4 insertions, 9 deletions
diff --git a/examples/menuapplet/config.in b/examples/menuapplet/config.in index 3167478..9425d9f 100644 --- a/examples/menuapplet/config.in +++ b/examples/menuapplet/config.in @@ -1,4 +1,4 @@ config EXAMPLE_MENU boolean "O-Menu Applet" default "y" - depends ( LIBQPE || LIBQPE-X11 ) && EXAMPLES + depends ( LIBQPE || LIBQPE-X11 ) && LIBOPIE2CORE && EXAMPLES diff --git a/examples/menuapplet/example.cpp b/examples/menuapplet/example.cpp index 8ae77da..079030f 100644 --- a/examples/menuapplet/example.cpp +++ b/examples/menuapplet/example.cpp @@ -1,8 +1,7 @@ #include "example.h" -#include <qpe/applnk.h> -#include <qpe/resource.h> +#include <opie2/oresource.h> /* QT */ #include <qiconset.h> #include <qpopupmenu.h> @@ -34,13 +33,9 @@ QString MenuAppletExample::text() const QIconSet MenuAppletExample::icon() const { - QPixmap pix; - QImage img = Resource::loadImage( "Tux" ); - if ( !img.isNull() ) - pix.convertFromImage( img.smoothScale( AppLnk::smallIconSize(), AppLnk::smallIconSize() ) ); - return pix; + return Opie::Core::OResource::loadPixmap( "Tux", Opie::Core::OResource::SmallIcon ); } QPopupMenu* MenuAppletExample::popup(QWidget*) const { diff --git a/examples/menuapplet/menuapplet.pro b/examples/menuapplet/menuapplet.pro index 1e20e78..e8858ec 100644 --- a/examples/menuapplet/menuapplet.pro +++ b/examples/menuapplet/menuapplet.pro @@ -5,8 +5,8 @@ SOURCES = example.cpp TARGET = example_applet DESTDIR = $(OPIEDIR)/plugins/applets INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += $(OPIEDIR)/include -LIBS += -lqpe +LIBS += -lqpe -lopiecore2 VERSION = 1.0.0 include( $(OPIEDIR)/include.pro ) |