-rw-r--r-- | core/applets/clipboardapplet/clipboard.cpp | 14 | ||||
-rw-r--r-- | core/applets/clipboardapplet/clipboardapplet.pro | 2 | ||||
-rw-r--r-- | core/applets/clipboardapplet/opie-clipboardapplet.control | 2 | ||||
-rw-r--r-- | core/applets/logoutapplet/logout.cpp | 9 | ||||
-rw-r--r-- | core/applets/logoutapplet/logoutapplet.pro | 2 |
5 files changed, 12 insertions, 17 deletions
diff --git a/core/applets/clipboardapplet/clipboard.cpp b/core/applets/clipboardapplet/clipboard.cpp index 57a4088..a32e98b 100644 --- a/core/applets/clipboardapplet/clipboard.cpp +++ b/core/applets/clipboardapplet/clipboard.cpp | |||
@@ -18,13 +18,14 @@ | |||
18 | ** | 18 | ** |
19 | **********************************************************************/ | 19 | **********************************************************************/ |
20 | 20 | ||
21 | #include "clipboard.h" | 21 | #include "clipboard.h" |
22 | 22 | ||
23 | #include <opie2/otaskbarapplet.h> | 23 | #include <opie2/otaskbarapplet.h> |
24 | #include <qpe/resource.h> | 24 | #include <opie2/oresource.h> |
25 | |||
25 | #include <qpe/applnk.h> | 26 | #include <qpe/applnk.h> |
26 | 27 | ||
27 | #include <qpainter.h> | 28 | #include <qpainter.h> |
28 | #include <qpopupmenu.h> | 29 | #include <qpopupmenu.h> |
29 | #include <qwindowsystem_qws.h> | 30 | #include <qwindowsystem_qws.h> |
30 | #include <qapplication.h> | 31 | #include <qapplication.h> |
@@ -37,16 +38,13 @@ | |||
37 | using namespace Opie::Ui; | 38 | using namespace Opie::Ui; |
38 | ClipboardApplet::ClipboardApplet( QWidget *parent, const char *name ) : QWidget( parent, name ) | 39 | ClipboardApplet::ClipboardApplet( QWidget *parent, const char *name ) : QWidget( parent, name ) |
39 | { | 40 | { |
40 | setFixedWidth ( AppLnk::smallIconSize() ); | 41 | setFixedWidth ( AppLnk::smallIconSize() ); |
41 | setFixedHeight ( AppLnk::smallIconSize() ); | 42 | setFixedHeight ( AppLnk::smallIconSize() ); |
42 | 43 | ||
43 | QImage img = Resource::loadImage( "paste"); | 44 | m_clipboardPixmap = Opie::Core::OResource::loadPixmap( "paste", Opie::Core::OResource::SmallIcon ); |
44 | img = img.smoothScale( AppLnk::smallIconSize(), AppLnk::smallIconSize() ); | ||
45 | |||
46 | m_clipboardPixmap.convertFromImage( img ); | ||
47 | 45 | ||
48 | m_timer = new QTimer ( this ); | 46 | m_timer = new QTimer ( this ); |
49 | 47 | ||
50 | connect ( QApplication::clipboard ( ), SIGNAL( dataChanged()), this, SLOT( newData())); | 48 | connect ( QApplication::clipboard ( ), SIGNAL( dataChanged()), this, SLOT( newData())); |
51 | connect ( m_timer, SIGNAL( timeout()), this, SLOT( newData())); | 49 | connect ( m_timer, SIGNAL( timeout()), this, SLOT( newData())); |
52 | connect ( qApp, SIGNAL( aboutToQuit()), this, SLOT( shutdown())); | 50 | connect ( qApp, SIGNAL( aboutToQuit()), this, SLOT( shutdown())); |
@@ -93,15 +91,15 @@ void ClipboardApplet::mousePressEvent ( QMouseEvent *) | |||
93 | m_menu-> insertItem ( QString ( "%1: %2" ). arg ( i + 1 ). arg ( str ), i ); | 91 | m_menu-> insertItem ( QString ( "%1: %2" ). arg ( i + 1 ). arg ( str ), i ); |
94 | m_menu-> setItemChecked ( i, false ); | 92 | m_menu-> setItemChecked ( i, false ); |
95 | } | 93 | } |
96 | m_menu-> setItemChecked ( m_history. count ( ) - 1, true ); | 94 | m_menu-> setItemChecked ( m_history. count ( ) - 1, true ); |
97 | m_menu-> insertSeparator ( ); | 95 | m_menu-> insertSeparator ( ); |
98 | } | 96 | } |
99 | m_menu-> insertItem ( QIconSet ( Resource::loadPixmap ( "cut" )), tr( "Cut" ), 100 ); | 97 | m_menu-> insertItem ( Opie::Core::OResource::loadPixmap( "cut", Opie::Core::OResource::SmallIcon ), tr( "Cut" ), 100 ); |
100 | m_menu-> insertItem ( QIconSet ( Resource::loadPixmap ( "copy" )), tr( "Copy" ), 101 ); | 98 | m_menu-> insertItem ( Opie::Core::OResource::loadPixmap( "copy", Opie::Core::OResource::SmallIcon ), tr( "Copy" ), 101 ); |
101 | m_menu-> insertItem ( QIconSet ( Resource::loadPixmap ( "paste" )), tr( "Paste" ), 102 ); | 99 | m_menu-> insertItem ( Opie::Core::OResource::loadPixmap( "paste", Opie::Core::OResource::SmallIcon ), tr( "Paste" ), 102 ); |
102 | 100 | ||
103 | connect ( m_menu, SIGNAL( activated(int)), this, SLOT( action(int))); | 101 | connect ( m_menu, SIGNAL( activated(int)), this, SLOT( action(int))); |
104 | 102 | ||
105 | m_dirty = false; | 103 | m_dirty = false; |
106 | } | 104 | } |
107 | QPoint p = mapToGlobal ( QPoint ( 0, 0 )); | 105 | QPoint p = mapToGlobal ( QPoint ( 0, 0 )); |
diff --git a/core/applets/clipboardapplet/clipboardapplet.pro b/core/applets/clipboardapplet/clipboardapplet.pro index 647598d..cdd0121 100644 --- a/core/applets/clipboardapplet/clipboardapplet.pro +++ b/core/applets/clipboardapplet/clipboardapplet.pro | |||
@@ -3,11 +3,11 @@ CONFIG += qt plugin warn_on | |||
3 | HEADERS = clipboard.h | 3 | HEADERS = clipboard.h |
4 | SOURCES = clipboard.cpp | 4 | SOURCES = clipboard.cpp |
5 | TARGET = clipboardapplet | 5 | TARGET = clipboardapplet |
6 | DESTDIR = $(OPIEDIR)/plugins/applets | 6 | DESTDIR = $(OPIEDIR)/plugins/applets |
7 | INCLUDEPATH += $(OPIEDIR)/include | 7 | INCLUDEPATH += $(OPIEDIR)/include |
8 | DEPENDPATH += | 8 | DEPENDPATH += |
9 | LIBS += -lqpe | 9 | LIBS += -lqpe -lopiecore2 |
10 | VERSION = 1.0.0 | 10 | VERSION = 1.0.0 |
11 | 11 | ||
12 | include( $(OPIEDIR)/include.pro ) | 12 | include( $(OPIEDIR)/include.pro ) |
13 | target.path = $$prefix/plugins/applets | 13 | target.path = $$prefix/plugins/applets |
diff --git a/core/applets/clipboardapplet/opie-clipboardapplet.control b/core/applets/clipboardapplet/opie-clipboardapplet.control index e0e2d82..6596633 100644 --- a/core/applets/clipboardapplet/opie-clipboardapplet.control +++ b/core/applets/clipboardapplet/opie-clipboardapplet.control | |||
@@ -1,10 +1,10 @@ | |||
1 | Package: opie-clipboardapplet | 1 | Package: opie-clipboardapplet |
2 | Files: plugins/applets/libclipboardapplet.so* | 2 | Files: plugins/applets/libclipboardapplet.so* |
3 | Priority: optional | 3 | Priority: optional |
4 | Section: opie/applets | 4 | Section: opie/applets |
5 | Maintainer: Robert Griebl <sandman@handhelds.org> | 5 | Maintainer: Robert Griebl <sandman@handhelds.org> |
6 | Architecture: arm | 6 | Architecture: arm |
7 | Depends: task-opie-minimal | 7 | Depends: task-opie-minimal, libopiecore2 |
8 | Description: Clipboard applet | 8 | Description: Clipboard applet |
9 | Clipboard applet for the Opie environment taskbar. | 9 | Clipboard applet for the Opie environment taskbar. |
10 | Version: $QPE_VERSION$EXTRAVERSION | 10 | Version: $QPE_VERSION$EXTRAVERSION |
diff --git a/core/applets/logoutapplet/logout.cpp b/core/applets/logoutapplet/logout.cpp index 0f36f16..dc0c67c 100644 --- a/core/applets/logoutapplet/logout.cpp +++ b/core/applets/logoutapplet/logout.cpp | |||
@@ -1,10 +1,11 @@ | |||
1 | #include "logout.h" | 1 | #include "logout.h" |
2 | 2 | ||
3 | #include <opie2/oresource.h> | ||
4 | |||
3 | #include <qpe/applnk.h> | 5 | #include <qpe/applnk.h> |
4 | #include <qpe/resource.h> | ||
5 | #include <qpe/qcopenvelope_qws.h> | 6 | #include <qpe/qcopenvelope_qws.h> |
6 | 7 | ||
7 | #include <qapplication.h> | 8 | #include <qapplication.h> |
8 | #include <qmessagebox.h> | 9 | #include <qmessagebox.h> |
9 | 10 | ||
10 | #include <unistd.h> | 11 | #include <unistd.h> |
@@ -42,17 +43,13 @@ QString LogoutApplet::tr( const char* s, const char* p ) const | |||
42 | { | 43 | { |
43 | return qApp->translate( "LogoutApplet", s, p ); | 44 | return qApp->translate( "LogoutApplet", s, p ); |
44 | } | 45 | } |
45 | 46 | ||
46 | QIconSet LogoutApplet::icon ( ) const | 47 | QIconSet LogoutApplet::icon ( ) const |
47 | { | 48 | { |
48 | QPixmap pix; | 49 | QPixmap pix = Opie::Core::OResource::loadPixmap("logout", Opie::Core::OResource::SmallIcon ); |
49 | QImage img = Resource::loadImage ( "logout" ); | ||
50 | |||
51 | if ( !img. isNull ( )) | ||
52 | pix.convertFromImage( img.smoothScale( AppLnk::smallIconSize(), AppLnk::smallIconSize() ) ); | ||
53 | return pix; | 50 | return pix; |
54 | } | 51 | } |
55 | 52 | ||
56 | QPopupMenu *LogoutApplet::popup ( QWidget * ) const | 53 | QPopupMenu *LogoutApplet::popup ( QWidget * ) const |
57 | { | 54 | { |
58 | return 0; | 55 | return 0; |
diff --git a/core/applets/logoutapplet/logoutapplet.pro b/core/applets/logoutapplet/logoutapplet.pro index 23cab02..5bb1571 100644 --- a/core/applets/logoutapplet/logoutapplet.pro +++ b/core/applets/logoutapplet/logoutapplet.pro | |||
@@ -3,11 +3,11 @@ CONFIG += qt plugin warn_on | |||
3 | HEADERS = logout.h | 3 | HEADERS = logout.h |
4 | SOURCES = logout.cpp | 4 | SOURCES = logout.cpp |
5 | TARGET = logoutapplet | 5 | TARGET = logoutapplet |
6 | DESTDIR = $(OPIEDIR)/plugins/applets | 6 | DESTDIR = $(OPIEDIR)/plugins/applets |
7 | INCLUDEPATH += $(OPIEDIR)/include | 7 | INCLUDEPATH += $(OPIEDIR)/include |
8 | DEPENDPATH += $(OPIEDIR)/include | 8 | DEPENDPATH += $(OPIEDIR)/include |
9 | LIBS += -lqpe | 9 | LIBS += -lqpe -lopiecore2 |
10 | VERSION = 1.0.0 | 10 | VERSION = 1.0.0 |
11 | 11 | ||
12 | include( $(OPIEDIR)/include.pro ) | 12 | include( $(OPIEDIR)/include.pro ) |
13 | target.path = $$prefix/plugins/applets | 13 | target.path = $$prefix/plugins/applets |