summaryrefslogtreecommitdiff
Side-by-side diff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--core/applets/suspendapplet/suspend.cpp9
-rw-r--r--core/applets/suspendapplet/suspendapplet.pro2
2 files changed, 4 insertions, 7 deletions
diff --git a/core/applets/suspendapplet/suspend.cpp b/core/applets/suspendapplet/suspend.cpp
index 4fbd704..f675766 100644
--- a/core/applets/suspendapplet/suspend.cpp
+++ b/core/applets/suspendapplet/suspend.cpp
@@ -1,16 +1,17 @@
#include "suspend.h"
+#include <opie2/oresource.h>
+
#include <qpe/applnk.h>
-#include <qpe/resource.h>
#include <qpe/qcopenvelope_qws.h>
#include <qapplication.h>
SuspendApplet::SuspendApplet ( )
: QObject ( 0, "SuspendApplet" )
{
}
SuspendApplet::~SuspendApplet ( )
{
}
@@ -33,29 +34,25 @@ QString SuspendApplet::text ( ) const
QString SuspendApplet::tr( const char* s ) const
{
return qApp->translate( "SuspendApplet", s, 0 );
}
QString SuspendApplet::tr( const char* s, const char* p ) const
{
return qApp->translate( "SuspendApplet", s, p );
}
QIconSet SuspendApplet::icon ( ) const
{
- QPixmap pix;
- QImage img = Resource::loadImage ( "suspend" );
-
- if ( !img. isNull ( ))
- pix.convertFromImage( img.smoothScale( AppLnk::smallIconSize(), AppLnk::smallIconSize() ) );
+ QPixmap pix = Opie::Core::OResource::loadPixmap( "suspend", Opie::Core::OResource::SmallIcon );
return pix;
}
QPopupMenu *SuspendApplet::popup ( QWidget * ) const
{
return 0;
}
void SuspendApplet::activated ( )
{
// suspend
QCopEnvelope ( "QPE/System", "suspend()" );
diff --git a/core/applets/suspendapplet/suspendapplet.pro b/core/applets/suspendapplet/suspendapplet.pro
index 6607383..5f139df 100644
--- a/core/applets/suspendapplet/suspendapplet.pro
+++ b/core/applets/suspendapplet/suspendapplet.pro
@@ -1,13 +1,13 @@
TEMPLATE = lib
CONFIG += qt plugin warn_on
HEADERS = suspend.h
SOURCES = suspend.cpp
TARGET = suspendapplet
DESTDIR = $(OPIEDIR)/plugins/applets
INCLUDEPATH += $(OPIEDIR)/include
DEPENDPATH += $(OPIEDIR)/include
-LIBS += -lqpe
+LIBS += -lqpe -lopiecore2
VERSION = 1.0.0
include( $(OPIEDIR)/include.pro )
target.path = $$prefix/plugins/applets