Diffstat (limited to 'noncore/net/networksetup/interfaces/interface.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/net/networksetup/interfaces/interface.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/noncore/net/networksetup/interfaces/interface.cpp b/noncore/net/networksetup/interfaces/interface.cpp index 4129b3d..7ffa76f 100644 --- a/noncore/net/networksetup/interfaces/interface.cpp +++ b/noncore/net/networksetup/interfaces/interface.cpp | |||
@@ -1,38 +1,38 @@ | |||
1 | #include "interface.h" | 1 | #include "interface.h" |
2 | #include <qdatetime.h> | 2 | #include <qdatetime.h> |
3 | #include <qfile.h> | 3 | #include <qfile.h> |
4 | #include <qdir.h> | 4 | #include <qdir.h> |
5 | #include <qfileinfo.h> | 5 | #include <qfileinfo.h> |
6 | #include <qtextstream.h> | 6 | #include <qtextstream.h> |
7 | 7 | ||
8 | #define IFCONFIG "/sbin/ifconfig" | 8 | #define IFCONFIG "/sbin/ifconfig" |
9 | #define DHCP_INFO_DIR "/etc/dhcpc" | 9 | #define DHCP_INFO_DIR "/etc/dhcpc" |
10 | 10 | ||
11 | #include <stdio.h> | 11 | #include <stdio.h> |
12 | #include <stdlib.h> | 12 | #include <stdlib.h> |
13 | 13 | ||
14 | Interface::Interface(QObject * parent, const char * name, bool newSatus): QObject(parent, name), status(newSatus), attached(false), hardwareName("Unknown"), moduleOwner(NULL), macAddress(""), ip("0.0.0.0"), broadcast(""), subnetMask("0.0.0.0"), dhcp(false){ | 14 | Interface::Interface(QObject * parent, const char * name, bool newSatus): QObject(parent, name), hardwareName("Unknown"), moduleOwner(NULL), status(newSatus), attached(false), dhcp(false), macAddress(""), ip("0.0.0.0"), broadcast(""), subnetMask("0.0.0.0"){ |
15 | refresh(); | 15 | refresh(); |
16 | } | 16 | } |
17 | 17 | ||
18 | /** | 18 | /** |
19 | * Set status | 19 | * Set status |
20 | * @param newStatus - the new status | 20 | * @param newStatus - the new status |
21 | * emit updateInterface | 21 | * emit updateInterface |
22 | */ | 22 | */ |
23 | void Interface::setStatus(bool newStatus){ | 23 | void Interface::setStatus(bool newStatus){ |
24 | if(status != newStatus){ | 24 | if(status != newStatus){ |
25 | status = newStatus; | 25 | status = newStatus; |
26 | refresh(); | 26 | refresh(); |
27 | } | 27 | } |
28 | }; | 28 | }; |
29 | 29 | ||
30 | /** | 30 | /** |
31 | * Set if attached or not (802.11 card pulled out for example) | 31 | * Set if attached or not (802.11 card pulled out for example) |
32 | * @param isAttached - if attached | 32 | * @param isAttached - if attached |
33 | * emit updateInterface | 33 | * emit updateInterface |
34 | */ | 34 | */ |
35 | void Interface::setAttached(bool isAttached){ | 35 | void Interface::setAttached(bool isAttached){ |
36 | attached = isAttached; | 36 | attached = isAttached; |
37 | emit(updateInterface(this)); | 37 | emit(updateInterface(this)); |
38 | }; | 38 | }; |