author | zecke <zecke> | 2004-03-13 21:53:54 (UTC) |
---|---|---|
committer | zecke <zecke> | 2004-03-13 21:53:54 (UTC) |
commit | 2eb5c075b612498c4b65f3d49389b8612612a930 (patch) (unidiff) | |
tree | a0230cd9007f71bbb387b71b8e58684937e0cf70 | |
parent | 184a0cd9935d0a249038cdbe05488c181b273d64 (diff) | |
download | opie-2eb5c075b612498c4b65f3d49389b8612612a930.zip opie-2eb5c075b612498c4b65f3d49389b8612612a930.tar.gz opie-2eb5c075b612498c4b65f3d49389b8612612a930.tar.bz2 |
Introduce the namespace
and the new APPLET_EXPORT define
-rw-r--r-- | noncore/applets/autorotateapplet/autorotate.cpp | 8 | ||||
-rw-r--r-- | noncore/applets/memoryapplet/memorymeter.cpp | 26 | ||||
-rw-r--r-- | noncore/applets/memoryapplet/memorystatus.cpp | 1 | ||||
-rw-r--r-- | noncore/applets/memoryapplet/memorystatus.h | 4 | ||||
-rw-r--r-- | noncore/applets/networkapplet/networkapplet.cpp | 7 | ||||
-rw-r--r-- | noncore/applets/networkapplet/networkapplet.h | 18 | ||||
-rw-r--r-- | noncore/applets/notesapplet/notes.cpp | 8 | ||||
-rw-r--r-- | noncore/applets/wirelessapplet/wireless.cpp | 9 | ||||
-rw-r--r-- | noncore/applets/wirelessapplet/wireless.h | 9 | ||||
-rw-r--r-- | noncore/applets/zkbapplet/zkbwidget.cpp | 11 |
10 files changed, 51 insertions, 50 deletions
diff --git a/noncore/applets/autorotateapplet/autorotate.cpp b/noncore/applets/autorotateapplet/autorotate.cpp index 94be0ae..ae7fbd0 100644 --- a/noncore/applets/autorotateapplet/autorotate.cpp +++ b/noncore/applets/autorotateapplet/autorotate.cpp | |||
@@ -24,4 +24,3 @@ | |||
24 | 24 | ||
25 | using namespace Opie; | 25 | using namespace Opie::Ui; |
26 | |||
27 | AutoRotate::AutoRotate(QWidget * parent):QWidget(parent) | 26 | AutoRotate::AutoRotate(QWidget * parent):QWidget(parent) |
@@ -96,6 +95,3 @@ bool AutoRotate::isRotateEnabled() | |||
96 | 95 | ||
97 | Q_EXPORT_INTERFACE() | 96 | EXPORT_OPIE_APPLET_v1( AutoRotate ) |
98 | { | ||
99 | Q_CREATE_INSTANCE( OTaskbarAppletWrapper<AutoRotate> ); | ||
100 | } | ||
101 | 97 | ||
diff --git a/noncore/applets/memoryapplet/memorymeter.cpp b/noncore/applets/memoryapplet/memorymeter.cpp index 9299f49..9cdeaf4 100644 --- a/noncore/applets/memoryapplet/memorymeter.cpp +++ b/noncore/applets/memoryapplet/memorymeter.cpp | |||
@@ -33,2 +33,3 @@ | |||
33 | 33 | ||
34 | using namespace Opie::Ui; | ||
34 | MemoryMeter::MemoryMeter( QWidget *parent ) | 35 | MemoryMeter::MemoryMeter( QWidget *parent ) |
@@ -37,3 +38,3 @@ MemoryMeter::MemoryMeter( QWidget *parent ) | |||
37 | bvsz = QSize(); | 38 | bvsz = QSize(); |
38 | if ( qApp->desktop()->height() >= 300 ) | 39 | if ( qApp->desktop()->height() >= 300 ) |
39 | { | 40 | { |
@@ -41,4 +42,4 @@ MemoryMeter::MemoryMeter( QWidget *parent ) | |||
41 | memoryView->setFrameStyle( QFrame::Panel | QFrame::Raised ); | 42 | memoryView->setFrameStyle( QFrame::Panel | QFrame::Raised ); |
42 | } | 43 | } |
43 | else | 44 | else |
44 | { | 45 | { |
@@ -81,3 +82,3 @@ bool MemoryMeter::updateMemoryViewGeometry() | |||
81 | QSize sz = memoryView->sizeHint(); | 82 | QSize sz = memoryView->sizeHint(); |
82 | if ( sz != bvsz ) | 83 | if ( sz != bvsz ) |
83 | { | 84 | { |
@@ -85,3 +86,3 @@ bool MemoryMeter::updateMemoryViewGeometry() | |||
85 | QRect r(memoryView->pos(), memoryView->sizeHint()); | 86 | QRect r(memoryView->pos(), memoryView->sizeHint()); |
86 | if ( qApp->desktop()->height() >= 300 ) | 87 | if ( qApp->desktop()->height() >= 300 ) |
87 | { | 88 | { |
@@ -102,7 +103,7 @@ void MemoryMeter::mousePressEvent( QMouseEvent *) | |||
102 | { | 103 | { |
103 | if ( memoryView->isVisible() ) | 104 | if ( memoryView->isVisible() ) |
104 | { | 105 | { |
105 | memoryView->hide(); | 106 | memoryView->hide(); |
106 | } | 107 | } |
107 | else | 108 | else |
108 | { | 109 | { |
@@ -208,3 +209,3 @@ void MemoryMeter::paintEvent( QPaintEvent* ) | |||
208 | // | 209 | // |
209 | if (used_height != 0) | 210 | if (used_height != 0) |
210 | { | 211 | { |
@@ -225,3 +226,3 @@ void MemoryMeter::paintEvent( QPaintEvent* ) | |||
225 | // | 226 | // |
226 | if ( batt_height - used_height > 0 ) | 227 | if ( batt_height - used_height > 0 ) |
227 | { | 228 | { |
@@ -242,6 +243,3 @@ void MemoryMeter::paintEvent( QPaintEvent* ) | |||
242 | 243 | ||
243 | Q_EXPORT_INTERFACE() | 244 | EXPORT_OPIE_APPLET_v1( MemoryMeter ) |
244 | { | ||
245 | Q_CREATE_INSTANCE( OTaskbarAppletWrapper<MemoryMeter> ); | ||
246 | } | ||
247 | 245 | ||
diff --git a/noncore/applets/memoryapplet/memorystatus.cpp b/noncore/applets/memoryapplet/memorystatus.cpp index c01ba28..95ae06b 100644 --- a/noncore/applets/memoryapplet/memorystatus.cpp +++ b/noncore/applets/memoryapplet/memorystatus.cpp | |||
@@ -30,2 +30,3 @@ | |||
30 | 30 | ||
31 | using namespace Opie::Ui; | ||
31 | MemoryStatus::MemoryStatus(QWidget *parent, WFlags f ) | 32 | MemoryStatus::MemoryStatus(QWidget *parent, WFlags f ) |
diff --git a/noncore/applets/memoryapplet/memorystatus.h b/noncore/applets/memoryapplet/memorystatus.h index c3926db..d16787b 100644 --- a/noncore/applets/memoryapplet/memorystatus.h +++ b/noncore/applets/memoryapplet/memorystatus.h | |||
@@ -28,3 +28,3 @@ class MemoryInfo; | |||
28 | class Swapfile; | 28 | class Swapfile; |
29 | using Opie::OTabWidget; | 29 | |
30 | 30 | ||
@@ -44,3 +44,3 @@ public: | |||
44 | private: | 44 | private: |
45 | OTabWidget *tab; | 45 | Opie::Ui::OTabWidget *tab; |
46 | }; | 46 | }; |
diff --git a/noncore/applets/networkapplet/networkapplet.cpp b/noncore/applets/networkapplet/networkapplet.cpp index 955ed2e..5eb5ad2 100644 --- a/noncore/applets/networkapplet/networkapplet.cpp +++ b/noncore/applets/networkapplet/networkapplet.cpp | |||
@@ -47,2 +47,4 @@ | |||
47 | 47 | ||
48 | using namespace Opie::Ui; | ||
49 | using namespace Opie::Net; | ||
48 | IfaceUpDownButton::IfaceUpDownButton( QWidget* parent, const char* name ) | 50 | IfaceUpDownButton::IfaceUpDownButton( QWidget* parent, const char* name ) |
@@ -248,7 +250,4 @@ void NetworkApplet::mousePressEvent( QMouseEvent* ) | |||
248 | 250 | ||
251 | EXPORT_OPIE_APPLET_v1( NetworkApplet ) | ||
249 | 252 | ||
250 | Q_EXPORT_INTERFACE() | ||
251 | { | ||
252 | Q_CREATE_INSTANCE( OTaskbarAppletWrapper<NetworkApplet> ); | ||
253 | } | ||
254 | 253 | ||
diff --git a/noncore/applets/networkapplet/networkapplet.h b/noncore/applets/networkapplet/networkapplet.h index 8022537..1e2cac8 100644 --- a/noncore/applets/networkapplet/networkapplet.h +++ b/noncore/applets/networkapplet/networkapplet.h | |||
@@ -40,3 +40,9 @@ | |||
40 | 40 | ||
41 | class ONetworkInterface; | 41 | |
42 | namespace Opie { | ||
43 | namespace Net { | ||
44 | class ONetwork; | ||
45 | class ONetworkInterface; | ||
46 | } | ||
47 | } | ||
42 | class QShowEvent; | 48 | class QShowEvent; |
@@ -57,3 +63,3 @@ class IfaceUpDownButton : public QToolButton | |||
57 | private: | 63 | private: |
58 | ONetworkInterface* _iface; | 64 | Opie::Net::ONetworkInterface* _iface; |
59 | }; | 65 | }; |
@@ -73,3 +79,3 @@ class IfaceIPAddress : public QLineEdit | |||
73 | private: | 79 | private: |
74 | ONetworkInterface* _iface; | 80 | Opie::Net::ONetworkInterface* _iface; |
75 | }; | 81 | }; |
@@ -79,3 +85,3 @@ class NetworkAppletControl : public QFrame | |||
79 | public: | 85 | public: |
80 | NetworkAppletControl( OTaskbarApplet* parent, const char* name = 0 ); | 86 | NetworkAppletControl( Opie::Ui::OTaskbarApplet* parent, const char* name = 0 ); |
81 | ~NetworkAppletControl(); | 87 | ~NetworkAppletControl(); |
@@ -87,3 +93,3 @@ class NetworkAppletControl : public QFrame | |||
87 | virtual void hideEvent( QHideEvent* ); | 93 | virtual void hideEvent( QHideEvent* ); |
88 | QString guessDevice( ONetworkInterface* iface ); | 94 | QString guessDevice( Opie::Net::ONetworkInterface* iface ); |
89 | void build(); | 95 | void build(); |
@@ -96,3 +102,3 @@ class NetworkAppletControl : public QFrame | |||
96 | 102 | ||
97 | class NetworkApplet : public OTaskbarApplet | 103 | class NetworkApplet : public Opie::Ui::OTaskbarApplet |
98 | { | 104 | { |
diff --git a/noncore/applets/notesapplet/notes.cpp b/noncore/applets/notesapplet/notes.cpp index 9b5e475..13f7cf3 100644 --- a/noncore/applets/notesapplet/notes.cpp +++ b/noncore/applets/notesapplet/notes.cpp | |||
@@ -48,2 +48,3 @@ | |||
48 | /* XPM */ | 48 | /* XPM */ |
49 | using namespace Opie::Ui; | ||
49 | static char * notes_xpm[] = { | 50 | static char * notes_xpm[] = { |
@@ -510,5 +511,4 @@ void NotesApplet::paintEvent( QPaintEvent* ) { | |||
510 | 511 | ||
511 | Q_EXPORT_INTERFACE() | 512 | |
512 | { | 513 | EXPORT_OPIE_APPLET_v1( NotesApplet ) |
513 | Q_CREATE_INSTANCE( OTaskbarAppletWrapper<NotesApplet> ); | 514 | |
514 | } | ||
diff --git a/noncore/applets/wirelessapplet/wireless.cpp b/noncore/applets/wirelessapplet/wireless.cpp index 6ef2e44..f244426 100644 --- a/noncore/applets/wirelessapplet/wireless.cpp +++ b/noncore/applets/wirelessapplet/wireless.cpp | |||
@@ -28,2 +28,3 @@ | |||
28 | #include <qpe/config.h> | 28 | #include <qpe/config.h> |
29 | #include <qpe/qpeapplication.h> | ||
29 | 30 | ||
@@ -50,2 +51,4 @@ | |||
50 | 51 | ||
52 | using namespace Opie::Ui; | ||
53 | using namespace Opie::Net; | ||
51 | WirelessControl::WirelessControl( WirelessApplet *applet, QWidget *parent, const char *name ) | 54 | WirelessControl::WirelessControl( WirelessApplet *applet, QWidget *parent, const char *name ) |
@@ -552,7 +555,3 @@ int WirelessApplet::position() | |||
552 | 555 | ||
553 | 556 | EXPORT_OPIE_APPLET_v1( WirelessApplet ) | |
554 | Q_EXPORT_INTERFACE() | ||
555 | { | ||
556 | Q_CREATE_INSTANCE( OTaskbarAppletWrapper<WirelessApplet> ); | ||
557 | } | ||
558 | 557 | ||
diff --git a/noncore/applets/wirelessapplet/wireless.h b/noncore/applets/wirelessapplet/wireless.h index 27f8c90..b475a46 100644 --- a/noncore/applets/wirelessapplet/wireless.h +++ b/noncore/applets/wirelessapplet/wireless.h | |||
@@ -21,3 +21,6 @@ | |||
21 | 21 | ||
22 | class OWirelessNetworkInterface; | 22 | namespace Opie {namespace Net { |
23 | class OWirelessNetworkInterface; | ||
24 | } | ||
25 | } | ||
23 | class Y; | 26 | class Y; |
@@ -88,3 +91,3 @@ class WirelessApplet : public QWidget | |||
88 | 91 | ||
89 | OWirelessNetworkInterface* interface; | 92 | Opie::Net::OWirelessNetworkInterface* interface; |
90 | 93 | ||
@@ -92,3 +95,3 @@ class WirelessApplet : public QWidget | |||
92 | const char** oldpixmap; | 95 | const char** oldpixmap; |
93 | OWirelessNetworkInterface* oldiface; | 96 | Opie::Net::OWirelessNetworkInterface* oldiface; |
94 | int oldqualityH; | 97 | int oldqualityH; |
diff --git a/noncore/applets/zkbapplet/zkbwidget.cpp b/noncore/applets/zkbapplet/zkbwidget.cpp index 0083e9b..3acff1e 100644 --- a/noncore/applets/zkbapplet/zkbwidget.cpp +++ b/noncore/applets/zkbapplet/zkbwidget.cpp | |||
@@ -10,2 +10,3 @@ | |||
10 | 10 | ||
11 | using namespace Opie::Ui; | ||
11 | ZkbWidget::ZkbWidget(QWidget* parent):QLabel(parent),keymap(0), | 12 | ZkbWidget::ZkbWidget(QWidget* parent):QLabel(parent),keymap(0), |
@@ -14,3 +15,3 @@ ZkbWidget::ZkbWidget(QWidget* parent):QLabel(parent),keymap(0), | |||
14 | labels = new QPopupMenu(); | 15 | labels = new QPopupMenu(); |
15 | connect(labels, SIGNAL(activated(int)), this, | 16 | connect(labels, SIGNAL(activated(int)), this, |
16 | SLOT(labelChanged(int))); | 17 | SLOT(labelChanged(int))); |
@@ -70,3 +71,3 @@ bool ZkbWidget::loadKeymap() { | |||
70 | w = 0; | 71 | w = 0; |
71 | for(QStringList::Iterator it = l.begin(); it != l.end(); | 72 | for(QStringList::Iterator it = l.begin(); it != l.end(); |
72 | ++it, n++) { | 73 | ++it, n++) { |
@@ -157,6 +158,4 @@ void ZkbWidget::reload() { | |||
157 | 158 | ||
158 | Q_EXPORT_INTERFACE() | 159 | EXPORT_OPIE_APPLET_v1( ZkbWidget ) |
159 | { | 160 | |
160 | Q_CREATE_INSTANCE( OTaskbarAppletWrapper<ZkbWidget> ); | ||
161 | } | ||
162 | 161 | ||