Diffstat (limited to 'noncore/settings/networksettings2/profile/profile_NN.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/settings/networksettings2/profile/profile_NN.cpp | 19 |
1 files changed, 1 insertions, 18 deletions
diff --git a/noncore/settings/networksettings2/profile/profile_NN.cpp b/noncore/settings/networksettings2/profile/profile_NN.cpp index 6028ea5..1e6912e 100644 --- a/noncore/settings/networksettings2/profile/profile_NN.cpp +++ b/noncore/settings/networksettings2/profile/profile_NN.cpp | |||
@@ -1,34 +1,30 @@ | |||
1 | #include <resources.h> | 1 | #include <resources.h> |
2 | #include "profile_NN.h" | 2 | #include "profile_NN.h" |
3 | #include "profile_NNI.h" | 3 | #include "profile_NNI.h" |
4 | 4 | ||
5 | #ifndef MYPLUGIN | ||
6 | |||
7 | #include "netnodeinterface.h" | 5 | #include "netnodeinterface.h" |
8 | 6 | ||
9 | #endif | ||
10 | |||
11 | static const char * ProfileNeeds[] = | 7 | static const char * ProfileNeeds[] = |
12 | { "connection", | 8 | { "connection", |
13 | 0 | 9 | 0 |
14 | }; | 10 | }; |
15 | static const char * ProfileProvides[] = | 11 | static const char * ProfileProvides[] = |
16 | { "fullsetup", | 12 | { "fullsetup", |
17 | 0 | 13 | 0 |
18 | }; | 14 | }; |
19 | 15 | ||
20 | /** | 16 | /** |
21 | * Constructor, find all of the possible interfaces | 17 | * Constructor, find all of the possible interfaces |
22 | */ | 18 | */ |
23 | ProfileNetNode::ProfileNetNode() : ANetNode( tr("Regular connection profile")) { | 19 | ProfileNetNode::ProfileNetNode() : ANetNode( tr("Regular connection profile")) { |
24 | 20 | ||
25 | NSResources->addSystemFile( | 21 | NSResources->addSystemFile( |
26 | "interfaces", "/etc/network/interfaces", 1 ); | 22 | "interfaces", "/etc/network/interfaces", 1 ); |
27 | 23 | ||
28 | } | 24 | } |
29 | 25 | ||
30 | /** | 26 | /** |
31 | * Delete any interfaces that we own. | 27 | * Delete any interfaces that we own. |
32 | */ | 28 | */ |
33 | ProfileNetNode::~ProfileNetNode(){ | 29 | ProfileNetNode::~ProfileNetNode(){ |
34 | } | 30 | } |
@@ -38,38 +34,25 @@ const QString ProfileNetNode::nodeDescription(){ | |||
38 | <p>Define use of an IP connection.</p>\ | 34 | <p>Define use of an IP connection.</p>\ |
39 | <p>Configure if and when this connection needs to be established</p>\ | 35 | <p>Configure if and when this connection needs to be established</p>\ |
40 | " | 36 | " |
41 | ); | 37 | ); |
42 | } | 38 | } |
43 | 39 | ||
44 | ANetNodeInstance * ProfileNetNode::createInstance( void ) { | 40 | ANetNodeInstance * ProfileNetNode::createInstance( void ) { |
45 | return new AProfile( this ); | 41 | return new AProfile( this ); |
46 | } | 42 | } |
47 | 43 | ||
48 | const char ** ProfileNetNode::needs( void ) { | 44 | const char ** ProfileNetNode::needs( void ) { |
49 | return ProfileNeeds; | 45 | return ProfileNeeds; |
50 | } | 46 | } |
51 | 47 | ||
52 | const char ** ProfileNetNode::provides( void ) { | 48 | const char ** ProfileNetNode::provides( void ) { |
53 | return ProfileProvides; | 49 | return ProfileProvides; |
54 | } | 50 | } |
55 | 51 | ||
56 | void ProfileNetNode::setSpecificAttribute( QString & , QString & ) { | 52 | void ProfileNetNode::setSpecificAttribute( QString & , QString & ) { |
57 | } | 53 | } |
58 | 54 | ||
59 | void ProfileNetNode::saveSpecificAttribute( QTextStream & ) { | 55 | void ProfileNetNode::saveSpecificAttribute( QTextStream & ) { |
60 | } | 56 | } |
61 | 57 | ||
62 | #ifdef MYPLUGIN | 58 | OPIE_NS2_PLUGIN( NetNodeInterface_T<ProfileNetNode> ) |
63 | |||
64 | extern "C" { | ||
65 | void create_plugin( QList<ANetNode> & PNN ) { | ||
66 | PNN.append( new ProfileNetNode() ); | ||
67 | } | ||
68 | |||
69 | #else | ||
70 | |||
71 | OPIE_NS2_PLUGIN( NetNodeInterface<ProfileNetNode> ) | ||
72 | |||
73 | #endif | ||
74 | |||
75 | } | ||