summaryrefslogtreecommitdiff
path: root/noncore/settings/networksettings2/networksettings2/systemfile.cpp
Unidiff
Diffstat (limited to 'noncore/settings/networksettings2/networksettings2/systemfile.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/settings/networksettings2/networksettings2/systemfile.cpp14
1 files changed, 6 insertions, 8 deletions
diff --git a/noncore/settings/networksettings2/networksettings2/systemfile.cpp b/noncore/settings/networksettings2/networksettings2/systemfile.cpp
index 394ff52..62bb6af 100644
--- a/noncore/settings/networksettings2/networksettings2/systemfile.cpp
+++ b/noncore/settings/networksettings2/networksettings2/systemfile.cpp
@@ -115,73 +115,71 @@ bool SystemFile::postSection( void ) {
115} 115}
116 116
117bool SystemFile::preNodeSection( ANetNodeInstance * NNI, long ) { 117bool SystemFile::preNodeSection( ANetNodeInstance * NNI, long ) {
118 if( hasPreNodeSection ) { 118 if( hasPreNodeSection ) {
119 QFile Fl( TemplDir + Name + "/prenodesection" ); 119 QFile Fl( TemplDir + Name + "/prenodesection" );
120 if( ! Fl.open( IO_ReadOnly ) ) 120 if( ! Fl.open( IO_ReadOnly ) )
121 return 1; // error 121 return 1; // error
122 QTextStream TX( &Fl ); 122 QTextStream TX( &Fl );
123 QString Out; 123 QString Out;
124 QString S = TX.readLine(); 124 QString S = TX.readLine();
125 while( ! TX.eof() ) { 125 while( ! TX.eof() ) {
126 Out = S. 126 Out = S.
127 arg(NNI->netNode()->nodeName()); 127 arg(NNI->nodeClass()->nodeName());
128 (*this) << Out << endl; 128 (*this) << Out << endl;
129 S = TX.readLine(); 129 S = TX.readLine();
130 } 130 }
131 } 131 }
132 return 0; 132 return 0;
133} 133}
134 134
135bool SystemFile::postNodeSection( ANetNodeInstance * NNI, long DevNr ) { 135bool SystemFile::postNodeSection( ANetNodeInstance * NNI, long ) {
136 if( hasPostNodeSection ) { 136 if( hasPostNodeSection ) {
137 QFile Fl( TemplDir + Name + "/postnodesection" ); 137 QFile Fl( TemplDir + Name + "/postnodesection" );
138 if( ! Fl.open( IO_ReadOnly ) ) 138 if( ! Fl.open( IO_ReadOnly ) )
139 return 1; // error 139 return 1; // error
140 QTextStream TX( &Fl ); 140 QTextStream TX( &Fl );
141 QString Out; 141 QString Out;
142 QString S = TX.readLine(); 142 QString S = TX.readLine();
143 while( ! TX.eof() ) { 143 while( ! TX.eof() ) {
144 Out = S. 144 Out = S.
145 arg(NNI->nodeName()); 145 arg(NNI->nodeName());
146 (*this) << Out << endl; 146 (*this) << Out << endl;
147 S = TX.readLine(); 147 S = TX.readLine();
148 } 148 }
149 } 149 }
150 return 0; 150 return 0;
151} 151}
152 152
153bool SystemFile::preDeviceSection( ANetNodeInstance * NNI, long ) { 153bool SystemFile::preDeviceSection( ANetNode * NN ) {
154 if( hasPreDeviceSection ) { 154 if( hasPreDeviceSection ) {
155 QFile Fl( TemplDir + Name + "/predevicesection" ); 155 QFile Fl( TemplDir + Name + "/predevicesection" );
156 if( ! Fl.open( IO_ReadOnly ) ) 156 if( ! Fl.open( IO_ReadOnly ) )
157 return 1; // error 157 return 1; // error
158 QTextStream TX( &Fl ); 158 QTextStream TX( &Fl );
159 QString Out; 159 QString Out;
160 QString S = TX.readLine(); 160 QString S = TX.readLine();
161 while( ! TX.eof() ) { 161 while( ! TX.eof() ) {
162 Out = S. 162 Out = S.arg(NN->nodeName());
163 arg(NNI->netNode()->nodeName());
164 (*this) << Out << endl; 163 (*this) << Out << endl;
165 S = TX.readLine(); 164 S = TX.readLine();
166 } 165 }
167 } 166 }
168 return 0; 167 return 0;
169} 168}
170 169
171bool SystemFile::postDeviceSection( ANetNodeInstance * NNI, long DevNr ) { 170bool SystemFile::postDeviceSection( ANetNode * NN ) {
172 if( hasPostDeviceSection ) { 171 if( hasPostDeviceSection ) {
173 QFile Fl( TemplDir + Name + "/postdevicesection" ); 172 QFile Fl( TemplDir + Name + "/postdevicesection" );
174 if( ! Fl.open( IO_ReadOnly ) ) 173 if( ! Fl.open( IO_ReadOnly ) )
175 return 1; // error 174 return 1; // error
176 QTextStream TX( &Fl ); 175 QTextStream TX( &Fl );
177 QString Out; 176 QString Out;
178 QString S = TX.readLine(); 177 QString S = TX.readLine();
179 while( ! TX.eof() ) { 178 while( ! TX.eof() ) {
180 Out = S. 179 Out = S.arg(NN->nodeName());
181 arg(NNI->nodeName());
182 (*this) << Out << endl; 180 (*this) << Out << endl;
183 S = TX.readLine(); 181 S = TX.readLine();
184 } 182 }
185 } 183 }
186 return 0; 184 return 0;
187} 185}