author | wimpie <wimpie> | 2004-04-05 22:58:06 (UTC) |
---|---|---|
committer | wimpie <wimpie> | 2004-04-05 22:58:06 (UTC) |
commit | 9aeac7cefc3c8baf32944e7275b57e0a0cde1515 (patch) (side-by-side diff) | |
tree | dc8161657d98d0e97d5f29554cb35d9b57202c49 /noncore/settings/networksettings2/lancard/lancard_NN.cpp | |
parent | 1d958f56a9e1357c20e76d763579d4dc184978e0 (diff) | |
download | opie-9aeac7cefc3c8baf32944e7275b57e0a0cde1515.zip opie-9aeac7cefc3c8baf32944e7275b57e0a0cde1515.tar.gz opie-9aeac7cefc3c8baf32944e7275b57e0a0cde1515.tar.bz2 |
Add save of node specific config data
Diffstat (limited to 'noncore/settings/networksettings2/lancard/lancard_NN.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/settings/networksettings2/lancard/lancard_NN.cpp | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/noncore/settings/networksettings2/lancard/lancard_NN.cpp b/noncore/settings/networksettings2/lancard/lancard_NN.cpp index 480ddf9..ba1c1f8 100644 --- a/noncore/settings/networksettings2/lancard/lancard_NN.cpp +++ b/noncore/settings/networksettings2/lancard/lancard_NN.cpp @@ -1,22 +1,23 @@ #include "lancard_NN.h" #include "lancard_NNI.h" static const char * LanCardNeeds[] = { 0 }; /** * Constructor, find all of the possible interfaces */ LanCardNetNode::LanCardNetNode() : ANetNode() { + InstanceCount = 2; } /** * Delete any interfaces that we own. */ LanCardNetNode::~LanCardNetNode(){ } const QString LanCardNetNode::nodeDescription(){ return tr("\ <p>Sets up a wired regular LAN card.</p>\ <p>Use this to set up 10/100/1000 MBit LAN cards.</p>\ @@ -56,17 +57,29 @@ bool LanCardNetNode::generateDeviceDataForCommonFile( S << "# check if " << NIC << " can be brought UP" << endl; S << "mapping " << NIC << endl; S << " script networksettings2-request" << endl << endl; } return 0; } QString LanCardNetNode::genNic( long nr ) { QString S; return S.sprintf( "eth%ld", nr ); } +void LanCardNetNode::setSpecificAttribute( QString & A, QString & V ) { + if( A == "interfacecount" ) { + InstanceCount = V.toLong(); + } +} + +void LanCardNetNode::saveSpecificAttribute( QTextStream & TS) { + TS << "interfacecount=" + << InstanceCount + << endl; +} + extern "C" { void create_plugin( QList<ANetNode> & PNN ) { PNN.append( new LanCardNetNode() ); } } |