-rw-r--r-- | noncore/applets/autorotateapplet/autorotate.cpp | 8 | ||||
-rw-r--r-- | noncore/applets/memoryapplet/memorymeter.cpp | 6 | ||||
-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 | 16 | ||||
-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 | 7 | ||||
-rw-r--r-- | noncore/applets/zkbapplet/zkbwidget.cpp | 7 |
10 files changed, 37 insertions, 36 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 @@ -21,10 +21,9 @@ /* QT */ #include <qpainter.h> -using namespace Opie; - +using namespace Opie::Ui; AutoRotate::AutoRotate(QWidget * parent):QWidget(parent) { setFixedWidth( AppLnk::smallIconSize() ); setFixedHeight( AppLnk::smallIconSize() ); @@ -93,9 +92,6 @@ bool AutoRotate::isRotateEnabled() qDebug("Disabled"); return res; } -Q_EXPORT_INTERFACE() -{ - Q_CREATE_INSTANCE( OTaskbarAppletWrapper<AutoRotate> ); -} +EXPORT_OPIE_APPLET_v1( AutoRotate ) 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 @@ -30,8 +30,9 @@ #include <qapplication.h> #include <qtopia/applnk.h> +using namespace Opie::Ui; MemoryMeter::MemoryMeter( QWidget *parent ) : QWidget( parent ), memoryView(0) { bvsz = QSize(); @@ -239,9 +240,6 @@ void MemoryMeter::paintEvent( QPaintEvent* ) p.drawRect(batt_xoffset + 3 * band_width, unused_offset, band_width, unused_height); } } -Q_EXPORT_INTERFACE() -{ - Q_CREATE_INSTANCE( OTaskbarAppletWrapper<MemoryMeter> ); -} +EXPORT_OPIE_APPLET_v1( MemoryMeter ) 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 @@ -27,8 +27,9 @@ #include <qlabel.h> #include <qlayout.h> +using namespace Opie::Ui; MemoryStatus::MemoryStatus(QWidget *parent, WFlags f ) : QFrame(parent, 0, f), mi(0), sf(0) { setCaption( tr("Memory Status") ); 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 @@ -25,9 +25,9 @@ #include <opie2/otabwidget.h> class MemoryInfo; class Swapfile; -using Opie::OTabWidget; + class MemoryStatus : public QFrame { Q_OBJECT @@ -41,9 +41,9 @@ public: int percent(); private: - OTabWidget *tab; + Opie::Ui::OTabWidget *tab; }; #endif 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 @@ -44,8 +44,10 @@ #include <qobjectlist.h> #include <assert.h> +using namespace Opie::Ui; +using namespace Opie::Net; IfaceUpDownButton::IfaceUpDownButton( QWidget* parent, const char* name ) :QToolButton( parent, name ) { _iface = ONetwork::instance()->interface( name ); @@ -245,10 +247,7 @@ void NetworkApplet::mousePressEvent( QMouseEvent* ) _control->hide(); } } +EXPORT_OPIE_APPLET_v1( NetworkApplet ) -Q_EXPORT_INTERFACE() -{ - Q_CREATE_INSTANCE( OTaskbarAppletWrapper<NetworkApplet> ); -} 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 @@ -37,9 +37,15 @@ #include <qtoolbutton.h> #include <qlineedit.h> #include <qpixmap.h> + +namespace Opie { +namespace Net { + class ONetwork; class ONetworkInterface; +} +} class QShowEvent; class QHideEvent; class QVBoxLayout; @@ -54,9 +60,9 @@ class IfaceUpDownButton : public QToolButton public slots: virtual void clicked(); private: - ONetworkInterface* _iface; + Opie::Net::ONetworkInterface* _iface; }; class IfaceIPAddress : public QLineEdit @@ -70,32 +76,32 @@ class IfaceIPAddress : public QLineEdit public slots: virtual void returnPressed(); private: - ONetworkInterface* _iface; + Opie::Net::ONetworkInterface* _iface; }; class NetworkAppletControl : public QFrame { public: - NetworkAppletControl( OTaskbarApplet* parent, const char* name = 0 ); + NetworkAppletControl( Opie::Ui::OTaskbarApplet* parent, const char* name = 0 ); ~NetworkAppletControl(); virtual QSize sizeHint() const; protected: virtual void showEvent( QShowEvent* ); virtual void hideEvent( QHideEvent* ); - QString guessDevice( ONetworkInterface* iface ); + QString guessDevice( Opie::Net::ONetworkInterface* iface ); void build(); private: QVBoxLayout* l; }; -class NetworkApplet : public OTaskbarApplet +class NetworkApplet : public Opie::Ui::OTaskbarApplet { public: NetworkApplet( QWidget* parent = 0, const char* name = 0 ); ~NetworkApplet(); 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 @@ -45,8 +45,9 @@ #include <qstring.h> #include <qtimer.h> /* XPM */ +using namespace Opie::Ui; static char * notes_xpm[] = { "16 16 11 1", " c None", ". c #000000", @@ -507,8 +508,7 @@ void NotesApplet::paintEvent( QPaintEvent* ) { QPainter p(this); p.drawPixmap( 0, 1, ( const char** ) notes_xpm ); } -Q_EXPORT_INTERFACE() -{ - Q_CREATE_INSTANCE( OTaskbarAppletWrapper<NotesApplet> ); -} + +EXPORT_OPIE_APPLET_v1( NotesApplet ) + 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 @@ -25,8 +25,9 @@ /* OPIE */ #include <opie2/onetwork.h> #include <opie2/otaskbarapplet.h> #include <qpe/config.h> +#include <qpe/qpeapplication.h> /* QT */ #include <qradiobutton.h> #include <qpushbutton.h> @@ -47,8 +48,10 @@ //#define MDEBUG #undef MDEBUG +using namespace Opie::Ui; +using namespace Opie::Net; WirelessControl::WirelessControl( WirelessApplet *applet, QWidget *parent, const char *name ) : QFrame( parent, name, WStyle_StaysOnTop | WType_Popup ), applet( applet ) { @@ -549,10 +552,6 @@ int WirelessApplet::position() { return 6; } - -Q_EXPORT_INTERFACE() -{ - Q_CREATE_INSTANCE( OTaskbarAppletWrapper<WirelessApplet> ); -} +EXPORT_OPIE_APPLET_v1( WirelessApplet ) 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 @@ -18,9 +18,12 @@ #include <qwidget.h> #include <qframe.h> #include <qpixmap.h> +namespace Opie {namespace Net { class OWirelessNetworkInterface; +} +} class Y; class QLabel; class WirelessApplet; class MGraph; @@ -85,13 +88,13 @@ class WirelessApplet : public QWidget QPixmap snapshotPixmap; int visualStyle; int timer; - OWirelessNetworkInterface* interface; + Opie::Net::OWirelessNetworkInterface* interface; private: const char** oldpixmap; - OWirelessNetworkInterface* oldiface; + Opie::Net::OWirelessNetworkInterface* oldiface; int oldqualityH; int oldsignalH; int oldnoiseH; 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 @@ -7,8 +7,9 @@ #include <unistd.h> #include "zkbwidget.h" #include "zkbcfg.h" +using namespace Opie::Ui; ZkbWidget::ZkbWidget(QWidget* parent):QLabel(parent),keymap(0), disabled(Resource::loadPixmap("zkb-disabled")) { labels = new QPopupMenu(); @@ -154,9 +155,7 @@ void ZkbWidget::reload() { loadKeymap(); QCopEnvelope("QPE/System", "notBusy()"); } -Q_EXPORT_INTERFACE() -{ - Q_CREATE_INSTANCE( OTaskbarAppletWrapper<ZkbWidget> ); -} +EXPORT_OPIE_APPLET_v1( ZkbWidget ) + |