summaryrefslogtreecommitdiff
path: root/noncore/settings/networksettings2/usb/usb_NN.cpp
Unidiff
Diffstat (limited to 'noncore/settings/networksettings2/usb/usb_NN.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/settings/networksettings2/usb/usb_NN.cpp23
1 files changed, 0 insertions, 23 deletions
diff --git a/noncore/settings/networksettings2/usb/usb_NN.cpp b/noncore/settings/networksettings2/usb/usb_NN.cpp
index c10a09c..14c479a 100644
--- a/noncore/settings/networksettings2/usb/usb_NN.cpp
+++ b/noncore/settings/networksettings2/usb/usb_NN.cpp
@@ -16,62 +16,39 @@ USBNetNode::USBNetNode() : ANetNode(tr("USB Cable Connect")) {
16 */ 16 */
17USBNetNode::~USBNetNode(){ 17USBNetNode::~USBNetNode(){
18} 18}
19 19
20const QString USBNetNode::nodeDescription(){ 20const QString USBNetNode::nodeDescription(){
21 return tr("\ 21 return tr("\
22<p>Configure Ethernet over USB.</p>\ 22<p>Configure Ethernet over USB.</p>\
23<p>Use this for a computer to computer USB cable connection</p>\ 23<p>Use this for a computer to computer USB cable connection</p>\
24" 24"
25); 25);
26} 26}
27 27
28ANetNodeInstance * USBNetNode::createInstance( void ) { 28ANetNodeInstance * USBNetNode::createInstance( void ) {
29 return new AUSB( this ); 29 return new AUSB( this );
30} 30}
31 31
32const char ** USBNetNode::needs( void ) { 32const char ** USBNetNode::needs( void ) {
33 return USBNeeds; 33 return USBNeeds;
34} 34}
35 35
36const char * USBNetNode::provides( void ) { 36const char * USBNetNode::provides( void ) {
37 return "device"; 37 return "device";
38} 38}
39 39
40bool USBNetNode::generateProperFilesFor(
41 ANetNodeInstance * ) {
42 return 0;
43}
44
45bool USBNetNode::hasDataFor( const QString & S ) {
46 return (S== "interfaces");
47}
48
49bool USBNetNode::generateDeviceDataForCommonFile(
50 SystemFile & S ,
51 long DevNr ) {
52 QString NIC = genNic( DevNr );
53
54 if( S.name() == "interfaces" ) {
55 // generate mapping stanza for this interface
56 S << "# check if " << NIC << " can be brought UP" << endl;
57 S << "mapping " << NIC << endl;
58 S << " script networksettings2-request" << endl << endl;
59 }
60 return 0;
61}
62
63QString USBNetNode::genNic( long ) { 40QString USBNetNode::genNic( long ) {
64 return QString( "usbf" ); 41 return QString( "usbf" );
65} 42}
66 43
67void USBNetNode::setSpecificAttribute( QString & , QString & ) { 44void USBNetNode::setSpecificAttribute( QString & , QString & ) {
68} 45}
69 46
70void USBNetNode::saveSpecificAttribute( QTextStream & ) { 47void USBNetNode::saveSpecificAttribute( QTextStream & ) {
71} 48}
72 49
73extern "C" { 50extern "C" {
74void create_plugin( QList<ANetNode> & PNN ) { 51void create_plugin( QList<ANetNode> & PNN ) {
75 PNN.append( new USBNetNode() ); 52 PNN.append( new USBNetNode() );
76} 53}
77} 54}