summaryrefslogtreecommitdiff
path: root/noncore/applets/wirelessapplet
Side-by-side diff
Diffstat (limited to 'noncore/applets/wirelessapplet') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/applets/wirelessapplet/wireless.cpp9
-rw-r--r--noncore/applets/wirelessapplet/wireless.h9
2 files changed, 10 insertions, 8 deletions
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
@@ -17,46 +17,49 @@
#include "connect0.xpm"
#include "connect1.xpm"
#include "connect2.xpm"
#include "connect3.xpm"
#include "connect4.xpm"
#include "connect5.xpm"
#include "nowireless.xpm"
/* OPIE */
#include <opie2/onetwork.h>
#include <opie2/otaskbarapplet.h>
#include <qpe/config.h>
+#include <qpe/qpeapplication.h>
/* QT */
#include <qradiobutton.h>
#include <qpushbutton.h>
#include <qpainter.h>
#include <qlabel.h>
#include <qslider.h>
#include <qbuttongroup.h>
#include <qlayout.h>
#include <qfile.h>
#include <qtextstream.h>
/* STD */
#include <sys/types.h>
#include <signal.h>
#define STYLE_BARS 0
#define STYLE_ANTENNA 1
//#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 )
{
readConfig();
writeConfigEntry( "UpdateFrequency", updateFrequency );
writeConfigEntry( "DisplayStyle", displayStyle );
setFrameStyle( QFrame::PopupPanel | QFrame::Raised );
QGridLayout *grid = new QGridLayout( this, 3, 2, 6, 2, "top layout" );
/* status label */
@@ -541,18 +544,14 @@ void WirelessApplet::paintEvent( QPaintEvent* )
p.setPen ( color );
p.drawLine( leftoffset, height() - bottomoffset - i, pixelWidth + leftoffset, height() - bottomoffset - i );
}
}
}
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
@@ -10,25 +10,28 @@
** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
**
**********************************************************************/
#ifndef __WIRELESS_APPLET_H__
#define __WIRELESS_APPLET_H__
#include <qwidget.h>
#include <qframe.h>
#include <qpixmap.h>
-class OWirelessNetworkInterface;
+namespace Opie {namespace Net {
+ class OWirelessNetworkInterface;
+}
+}
class Y;
class QLabel;
class WirelessApplet;
class MGraph;
class WirelessControl : public QFrame
{
Q_OBJECT
public:
WirelessControl( WirelessApplet* icon, QWidget *parent=0, const char *name=0 );
void show( bool );
@@ -77,29 +80,29 @@ class WirelessApplet : public QWidget
void checkInterface();
void renewDHCP();
bool mustRepaint();
void updatePopupWindow();
const char** getQualityPixmap();
private:
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;
QString oldESSID;
QString oldAP;
QString oldMODE;
double oldFREQ;
bool rocESSID;
bool rocFREQ;
bool rocAP;