summaryrefslogtreecommitdiff
path: root/noncore
authormickeyl <mickeyl>2005-05-17 16:57:08 (UTC)
committer mickeyl <mickeyl>2005-05-17 16:57:08 (UTC)
commitd2ae68c413873e234b34f733818427902e738948 (patch) (unidiff)
treef5748014d7b1785302c167c6f43fbd0622bf1019 /noncore
parentcce15d6b9a27880df72ea2638f9295900ea6c21e (diff)
downloadopie-d2ae68c413873e234b34f733818427902e738948.zip
opie-d2ae68c413873e234b34f733818427902e738948.tar.gz
opie-d2ae68c413873e234b34f733818427902e738948.tar.bz2
libopienet API cleanups
Diffstat (limited to 'noncore') (more/less context) (show whitespace changes)
-rw-r--r--noncore/applets/networkapplet/networkapplet.cpp6
-rw-r--r--noncore/net/opiestumbler/opiestumbler.cpp2
2 files changed, 4 insertions, 4 deletions
diff --git a/noncore/applets/networkapplet/networkapplet.cpp b/noncore/applets/networkapplet/networkapplet.cpp
index 534a8d0..bd6ca66 100644
--- a/noncore/applets/networkapplet/networkapplet.cpp
+++ b/noncore/applets/networkapplet/networkapplet.cpp
@@ -74,43 +74,43 @@ void IfaceUpDownButton::clicked()
74 _iface->setUp( isOn() ); 74 _iface->setUp( isOn() );
75 setOn( _iface->isUp() ); // it might not have worked... 75 setOn( _iface->isUp() ); // it might not have worked...
76 repaint(); 76 repaint();
77} 77}
78 78
79 79
80IfaceIPAddress::IfaceIPAddress( QWidget* parent, const char* name ) 80IfaceIPAddress::IfaceIPAddress( QWidget* parent, const char* name )
81 :QLineEdit( parent, name ) 81 :QLineEdit( parent, name )
82{ 82{
83 setFont( QFont( "fixed" ) ); 83 setFont( QFont( "fixed" ) );
84 _iface = ONetwork::instance()->interface( name ); 84 _iface = ONetwork::instance()->interface( name );
85 setFixedWidth( 105 ); 85 setFixedWidth( 105 );
86 setText( _iface->ipV4Address() ); 86 setText( _iface->ipV4Address().toString() );
87 connect( this, SIGNAL( returnPressed() ), this, SLOT( returnPressed() ) ); 87 connect( this, SIGNAL( returnPressed() ), this, SLOT( returnPressed() ) );
88} 88}
89 89
90 90
91IfaceIPAddress::~IfaceIPAddress() 91IfaceIPAddress::~IfaceIPAddress()
92{ 92{
93} 93}
94 94
95 95
96void IfaceIPAddress::returnPressed() 96void IfaceIPAddress::returnPressed()
97{ 97{
98 QHostAddress a; 98 QHostAddress a;
99 a.setAddress( text() ); 99 a.setAddress( text() );
100 QHostAddress mask; 100 QHostAddress mask;
101 mask.setAddress( _iface->ipV4Netmask() ); // setIPV4Address destroys the netmask... 101 mask.setAddress( _iface->ipV4Netmask().toString() ); // setIPV4Address destroys the netmask...
102 _iface->setIPV4Address( a ); 102 _iface->setIPV4Address( a );
103 _iface->setIPV4Netmask( mask ); // recover the old netmask 103 _iface->setIPV4Netmask( mask ); // recover the old netmask
104 setText( _iface->ipV4Address() ); 104 setText( _iface->ipV4Address().toString() );
105 repaint(); 105 repaint();
106} 106}
107 107
108 108
109NetworkAppletControl::NetworkAppletControl( OTaskbarApplet* parent, const char* name ) 109NetworkAppletControl::NetworkAppletControl( OTaskbarApplet* parent, const char* name )
110 :QFrame( parent, name, WStyle_StaysOnTop | WType_Popup ), l(0) 110 :QFrame( parent, name, WStyle_StaysOnTop | WType_Popup ), l(0)
111{ 111{
112 setFrameStyle( QFrame::PopupPanel | QFrame::Raised ); 112 setFrameStyle( QFrame::PopupPanel | QFrame::Raised );
113 l = new QVBoxLayout( this, 4, 2 ); 113 l = new QVBoxLayout( this, 4, 2 );
114} 114}
115 115
116 116
diff --git a/noncore/net/opiestumbler/opiestumbler.cpp b/noncore/net/opiestumbler/opiestumbler.cpp
index 8dedd67..f231fca 100644
--- a/noncore/net/opiestumbler/opiestumbler.cpp
+++ b/noncore/net/opiestumbler/opiestumbler.cpp
@@ -327,22 +327,22 @@ void OpieStumbler::slotAssociated()
327void OpieStumbler::slotCheckDHCP() 327void OpieStumbler::slotCheckDHCP()
328{ 328{
329 if(!m_proc->isRunning()) { 329 if(!m_proc->isRunning()) {
330 Global::statusMessage(tr("Could not Obtain an Address")); 330 Global::statusMessage(tr("Could not Obtain an Address"));
331 delete m_proc; 331 delete m_proc;
332 m_proc = NULL; 332 m_proc = NULL;
333 return; 333 return;
334 } 334 }
335 m_listCurrent->show(); 335 m_listCurrent->show();
336 336
337 337
338 OWirelessNetworkInterface *wiface = static_cast<OWirelessNetworkInterface*>(ONetwork::instance()->interface(m_interface)); 338 OWirelessNetworkInterface *wiface = static_cast<OWirelessNetworkInterface*>(ONetwork::instance()->interface(m_interface));
339 Global::statusMessage(tr("Obtained IP ") + wiface->ipV4Address()); 339 Global::statusMessage(tr("Obtained IP ") + wiface->ipV4Address().toString());
340} 340}
341 341
342 342
343 343
344 344
345 345
346 346
347 347
348 348