summaryrefslogtreecommitdiff
path: root/noncore/applets/networkapplet/networkapplet.cpp
Unidiff
Diffstat (limited to 'noncore/applets/networkapplet/networkapplet.cpp') (more/less context) (show whitespace changes)
-rw-r--r--noncore/applets/networkapplet/networkapplet.cpp16
1 files changed, 9 insertions, 7 deletions
diff --git a/noncore/applets/networkapplet/networkapplet.cpp b/noncore/applets/networkapplet/networkapplet.cpp
index 5eb5ad2..534a8d0 100644
--- a/noncore/applets/networkapplet/networkapplet.cpp
+++ b/noncore/applets/networkapplet/networkapplet.cpp
@@ -36,17 +36,19 @@
36#include <opie2/otaskbarapplet.h> 36#include <opie2/otaskbarapplet.h>
37#include <qpe/applnk.h> 37#include <qpe/applnk.h>
38#include <qpe/resource.h> 38#include <qpe/resource.h>
39#include <qpainter.h> 39using namespace Opie::Core;
40using namespace Opie::Ui;
41using namespace Opie::Net;
40 42
41/* QT */ 43/* QT */
44#include <qpainter.h>
42#include <qlabel.h> 45#include <qlabel.h>
43#include <qlayout.h> 46#include <qlayout.h>
44#include <qobjectlist.h> 47#include <qobjectlist.h>
45 48
49/* STD */
46#include <assert.h> 50#include <assert.h>
47 51
48using namespace Opie::Ui;
49using namespace Opie::Net;
50IfaceUpDownButton::IfaceUpDownButton( QWidget* parent, const char* name ) 52IfaceUpDownButton::IfaceUpDownButton( QWidget* parent, const char* name )
51 :QToolButton( parent, name ) 53 :QToolButton( parent, name )
52{ 54{
@@ -167,7 +169,7 @@ QString NetworkAppletControl::guessDevice( ONetworkInterface* iface )
167 169
168void NetworkAppletControl::showEvent( QShowEvent* e ) 170void NetworkAppletControl::showEvent( QShowEvent* e )
169{ 171{
170 qDebug( "showEvent" ); 172 odebug << "showEvent" << oendl;
171 build(); 173 build();
172 QWidget::showEvent( e ); 174 QWidget::showEvent( e );
173} 175}
@@ -175,7 +177,7 @@ void NetworkAppletControl::showEvent( QShowEvent* e )
175 177
176void NetworkAppletControl::hideEvent( QHideEvent* e ) 178void NetworkAppletControl::hideEvent( QHideEvent* e )
177{ 179{
178 qDebug( "hideEvent" ); 180 odebug << "hideEvent" << oendl;
179 QWidget::hideEvent( e ); 181 QWidget::hideEvent( e );
180 182
181 delete l; 183 delete l;
@@ -192,7 +194,7 @@ void NetworkAppletControl::hideEvent( QHideEvent* e )
192 194
193 list = const_cast<QObjectList*>( children() ); 195 list = const_cast<QObjectList*>( children() );
194 if ( list ) 196 if ( list )
195 qWarning( "D'oh! We still have %d children...", list->count() ); 197 owarn << "D'oh! We still have " << list->count() << " children..." << oendl;
196 198
197 // renew layout 199 // renew layout
198 l = new QVBoxLayout( this, 4, 2 ); 200 l = new QVBoxLayout( this, 4, 2 );
@@ -203,7 +205,7 @@ void NetworkAppletControl::hideEvent( QHideEvent* e )
203QSize NetworkAppletControl::sizeHint() const 205QSize NetworkAppletControl::sizeHint() const
204{ 206{
205 ONetwork::instance()->synchronize(); // rebuild interface database 207 ONetwork::instance()->synchronize(); // rebuild interface database
206 qDebug( "sizeHint (#ifaces=%d)", ONetwork::instance()->count() ); 208 odebug << "sizeHint (#ifaces=" << ONetwork::instance()->count() << ")" << oendl;
207 return QSize( 14+35+105+14 + 8, ONetwork::instance()->count() * 26 ); 209 return QSize( 14+35+105+14 + 8, ONetwork::instance()->count() * 26 );
208} 210}
209 211