summaryrefslogtreecommitdiff
authormickeyl <mickeyl>2003-08-11 19:04:52 (UTC)
committer mickeyl <mickeyl>2003-08-11 19:04:52 (UTC)
commite7f79ca3acf58aef3ff150a2974f8087189621f5 (patch) (unidiff)
treeb8397506f85d9a3b547940e416111de4b2da1f18
parent62cb34a352c38f97967882a7ac604d9670f0e75f (diff)
downloadopie-e7f79ca3acf58aef3ff150a2974f8087189621f5.zip
opie-e7f79ca3acf58aef3ff150a2974f8087189621f5.tar.gz
opie-e7f79ca3acf58aef3ff150a2974f8087189621f5.tar.bz2
assorted fixes and more work on GPS
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/net/wellenreiter/gui/configbase.ui52
-rw-r--r--noncore/net/wellenreiter/gui/configwindow.cpp20
-rw-r--r--noncore/net/wellenreiter/gui/configwindow.h4
-rw-r--r--noncore/net/wellenreiter/gui/gps.cpp48
-rw-r--r--noncore/net/wellenreiter/gui/gps.h19
-rw-r--r--noncore/net/wellenreiter/gui/wellenreiter.cpp40
-rw-r--r--noncore/net/wellenreiter/gui/wellenreiter.h2
7 files changed, 153 insertions, 32 deletions
diff --git a/noncore/net/wellenreiter/gui/configbase.ui b/noncore/net/wellenreiter/gui/configbase.ui
index c1da98d..d9a0aea 100644
--- a/noncore/net/wellenreiter/gui/configbase.ui
+++ b/noncore/net/wellenreiter/gui/configbase.ui
@@ -1,1226 +1,1230 @@
1<!DOCTYPE UI><UI> 1<!DOCTYPE UI><UI>
2<class>WellenreiterConfigBase</class> 2<class>WellenreiterConfigBase</class>
3<widget> 3<widget>
4 <class>QDialog</class> 4 <class>QDialog</class>
5 <property stdset="1"> 5 <property stdset="1">
6 <name>name</name> 6 <name>name</name>
7 <cstring>WellenreiterConfigBase</cstring> 7 <cstring>WellenreiterConfigBase</cstring>
8 </property> 8 </property>
9 <property stdset="1"> 9 <property stdset="1">
10 <name>geometry</name> 10 <name>geometry</name>
11 <rect> 11 <rect>
12 <x>0</x> 12 <x>0</x>
13 <y>0</y> 13 <y>0</y>
14 <width>286</width> 14 <width>286</width>
15 <height>280</height> 15 <height>280</height>
16 </rect> 16 </rect>
17 </property> 17 </property>
18 <property stdset="1"> 18 <property stdset="1">
19 <name>caption</name> 19 <name>caption</name>
20 <string>Wellenreiter II COnfiguration Dialog</string> 20 <string>Wellenreiter II COnfiguration Dialog</string>
21 </property> 21 </property>
22 <property> 22 <property>
23 <name>layoutMargin</name> 23 <name>layoutMargin</name>
24 </property> 24 </property>
25 <property> 25 <property>
26 <name>layoutSpacing</name> 26 <name>layoutSpacing</name>
27 </property> 27 </property>
28 <grid> 28 <grid>
29 <property stdset="1"> 29 <property stdset="1">
30 <name>margin</name> 30 <name>margin</name>
31 <number>2</number> 31 <number>2</number>
32 </property> 32 </property>
33 <property stdset="1"> 33 <property stdset="1">
34 <name>spacing</name> 34 <name>spacing</name>
35 <number>3</number> 35 <number>3</number>
36 </property> 36 </property>
37 <widget row="0" column="0" > 37 <widget row="0" column="0" >
38 <class>QTabWidget</class> 38 <class>QTabWidget</class>
39 <property stdset="1"> 39 <property stdset="1">
40 <name>name</name> 40 <name>name</name>
41 <cstring>tab</cstring> 41 <cstring>tab</cstring>
42 </property> 42 </property>
43 <property> 43 <property>
44 <name>layoutMargin</name> 44 <name>layoutMargin</name>
45 </property> 45 </property>
46 <property> 46 <property>
47 <name>layoutSpacing</name> 47 <name>layoutSpacing</name>
48 </property> 48 </property>
49 <widget> 49 <widget>
50 <class>QWidget</class> 50 <class>QWidget</class>
51 <property stdset="1"> 51 <property stdset="1">
52 <name>name</name> 52 <name>name</name>
53 <cstring>tab</cstring> 53 <cstring>tab</cstring>
54 </property> 54 </property>
55 <attribute> 55 <attribute>
56 <name>title</name> 56 <name>title</name>
57 <string>Interface</string> 57 <string>Interface</string>
58 </attribute> 58 </attribute>
59 <grid> 59 <grid>
60 <property stdset="1"> 60 <property stdset="1">
61 <name>margin</name> 61 <name>margin</name>
62 <number>5</number> 62 <number>5</number>
63 </property> 63 </property>
64 <property stdset="1"> 64 <property stdset="1">
65 <name>spacing</name> 65 <name>spacing</name>
66 <number>3</number> 66 <number>3</number>
67 </property> 67 </property>
68 <widget row="0" column="0" > 68 <widget row="0" column="0" >
69 <class>QLabel</class> 69 <class>QLabel</class>
70 <property stdset="1"> 70 <property stdset="1">
71 <name>name</name> 71 <name>name</name>
72 <cstring>TextLabel1_2</cstring> 72 <cstring>TextLabel1_2</cstring>
73 </property> 73 </property>
74 <property stdset="1"> 74 <property stdset="1">
75 <name>enabled</name> 75 <name>enabled</name>
76 <bool>true</bool> 76 <bool>true</bool>
77 </property> 77 </property>
78 <property stdset="1"> 78 <property stdset="1">
79 <name>text</name> 79 <name>text</name>
80 <string>Name:</string> 80 <string>Name:</string>
81 </property> 81 </property>
82 </widget> 82 </widget>
83 <widget row="1" column="0" > 83 <widget row="1" column="0" >
84 <class>QLabel</class> 84 <class>QLabel</class>
85 <property stdset="1"> 85 <property stdset="1">
86 <name>name</name> 86 <name>name</name>
87 <cstring>TextLabel2_3</cstring> 87 <cstring>TextLabel2_3</cstring>
88 </property> 88 </property>
89 <property stdset="1"> 89 <property stdset="1">
90 <name>enabled</name> 90 <name>enabled</name>
91 <bool>true</bool> 91 <bool>true</bool>
92 </property> 92 </property>
93 <property stdset="1"> 93 <property stdset="1">
94 <name>text</name> 94 <name>text</name>
95 <string>Driver:</string> 95 <string>Driver:</string>
96 </property> 96 </property>
97 </widget> 97 </widget>
98 <widget row="2" column="0" rowspan="1" colspan="4" > 98 <widget row="2" column="0" rowspan="1" colspan="4" >
99 <class>QCheckBox</class> 99 <class>QCheckBox</class>
100 <property stdset="1"> 100 <property stdset="1">
101 <name>name</name> 101 <name>name</name>
102 <cstring>prismHeader</cstring> 102 <cstring>prismHeader</cstring>
103 </property> 103 </property>
104 <property stdset="1"> 104 <property stdset="1">
105 <name>text</name> 105 <name>text</name>
106 <string>Use additional PRISM header</string> 106 <string>Use additional PRISM header</string>
107 </property> 107 </property>
108 </widget> 108 </widget>
109 <widget row="6" column="0" rowspan="1" colspan="4" > 109 <widget row="6" column="0" rowspan="1" colspan="4" >
110 <class>QGroupBox</class> 110 <class>QGroupBox</class>
111 <property stdset="1"> 111 <property stdset="1">
112 <name>name</name> 112 <name>name</name>
113 <cstring>GroupBox1</cstring> 113 <cstring>GroupBox1</cstring>
114 </property> 114 </property>
115 <property stdset="1"> 115 <property stdset="1">
116 <name>enabled</name> 116 <name>enabled</name>
117 <bool>false</bool> 117 <bool>false</bool>
118 </property> 118 </property>
119 <property stdset="1"> 119 <property stdset="1">
120 <name>title</name> 120 <name>title</name>
121 <string>Scan on channel</string> 121 <string>Scan on channel</string>
122 </property> 122 </property>
123 <property> 123 <property>
124 <name>layoutMargin</name> 124 <name>layoutMargin</name>
125 </property> 125 </property>
126 <property> 126 <property>
127 <name>layoutSpacing</name> 127 <name>layoutSpacing</name>
128 </property> 128 </property>
129 <grid> 129 <grid>
130 <property stdset="1"> 130 <property stdset="1">
131 <name>margin</name> 131 <name>margin</name>
132 <number>4</number> 132 <number>4</number>
133 </property> 133 </property>
134 <property stdset="1"> 134 <property stdset="1">
135 <name>spacing</name> 135 <name>spacing</name>
136 <number>2</number> 136 <number>2</number>
137 </property> 137 </property>
138 <widget row="1" column="1" > 138 <widget row="1" column="1" >
139 <class>QCheckBox</class> 139 <class>QCheckBox</class>
140 <property stdset="1"> 140 <property stdset="1">
141 <name>name</name> 141 <name>name</name>
142 <cstring>channel6</cstring> 142 <cstring>channel6</cstring>
143 </property> 143 </property>
144 <property stdset="1"> 144 <property stdset="1">
145 <name>text</name> 145 <name>text</name>
146 <string>6</string> 146 <string>6</string>
147 </property> 147 </property>
148 </widget> 148 </widget>
149 <widget row="1" column="3" > 149 <widget row="1" column="3" >
150 <class>QCheckBox</class> 150 <class>QCheckBox</class>
151 <property stdset="1"> 151 <property stdset="1">
152 <name>name</name> 152 <name>name</name>
153 <cstring>channel8</cstring> 153 <cstring>channel8</cstring>
154 </property> 154 </property>
155 <property stdset="1"> 155 <property stdset="1">
156 <name>text</name> 156 <name>text</name>
157 <string>8</string> 157 <string>8</string>
158 </property> 158 </property>
159 </widget> 159 </widget>
160 <widget row="0" column="2" > 160 <widget row="0" column="2" >
161 <class>QCheckBox</class> 161 <class>QCheckBox</class>
162 <property stdset="1"> 162 <property stdset="1">
163 <name>name</name> 163 <name>name</name>
164 <cstring>channel2</cstring> 164 <cstring>channel2</cstring>
165 </property> 165 </property>
166 <property stdset="1"> 166 <property stdset="1">
167 <name>text</name> 167 <name>text</name>
168 <string>2</string> 168 <string>2</string>
169 </property> 169 </property>
170 </widget> 170 </widget>
171 <widget row="1" column="4" > 171 <widget row="1" column="4" >
172 <class>QCheckBox</class> 172 <class>QCheckBox</class>
173 <property stdset="1"> 173 <property stdset="1">
174 <name>name</name> 174 <name>name</name>
175 <cstring>channel9</cstring> 175 <cstring>channel9</cstring>
176 </property> 176 </property>
177 <property stdset="1"> 177 <property stdset="1">
178 <name>text</name> 178 <name>text</name>
179 <string>9</string> 179 <string>9</string>
180 </property> 180 </property>
181 </widget> 181 </widget>
182 <widget row="0" column="1" > 182 <widget row="0" column="1" >
183 <class>QCheckBox</class> 183 <class>QCheckBox</class>
184 <property stdset="1"> 184 <property stdset="1">
185 <name>name</name> 185 <name>name</name>
186 <cstring>channel1</cstring> 186 <cstring>channel1</cstring>
187 </property> 187 </property>
188 <property stdset="1"> 188 <property stdset="1">
189 <name>text</name> 189 <name>text</name>
190 <string>1</string> 190 <string>1</string>
191 </property> 191 </property>
192 </widget> 192 </widget>
193 <widget row="0" column="0" > 193 <widget row="0" column="0" >
194 <class>QCheckBox</class> 194 <class>QCheckBox</class>
195 <property stdset="1"> 195 <property stdset="1">
196 <name>name</name> 196 <name>name</name>
197 <cstring>channelAll</cstring> 197 <cstring>channelAll</cstring>
198 </property> 198 </property>
199 <property stdset="1"> 199 <property stdset="1">
200 <name>text</name> 200 <name>text</name>
201 <string>All</string> 201 <string>All</string>
202 </property> 202 </property>
203 </widget> 203 </widget>
204 <widget row="2" column="1" > 204 <widget row="2" column="1" >
205 <class>QCheckBox</class> 205 <class>QCheckBox</class>
206 <property stdset="1"> 206 <property stdset="1">
207 <name>name</name> 207 <name>name</name>
208 <cstring>channel11</cstring> 208 <cstring>channel11</cstring>
209 </property> 209 </property>
210 <property stdset="1"> 210 <property stdset="1">
211 <name>text</name> 211 <name>text</name>
212 <string>11</string> 212 <string>11</string>
213 </property> 213 </property>
214 </widget> 214 </widget>
215 <widget row="2" column="0" > 215 <widget row="2" column="0" >
216 <class>QCheckBox</class> 216 <class>QCheckBox</class>
217 <property stdset="1"> 217 <property stdset="1">
218 <name>name</name> 218 <name>name</name>
219 <cstring>channel10</cstring> 219 <cstring>channel10</cstring>
220 </property> 220 </property>
221 <property stdset="1"> 221 <property stdset="1">
222 <name>text</name> 222 <name>text</name>
223 <string>10</string> 223 <string>10</string>
224 </property> 224 </property>
225 </widget> 225 </widget>
226 <widget row="1" column="2" > 226 <widget row="1" column="2" >
227 <class>QCheckBox</class> 227 <class>QCheckBox</class>
228 <property stdset="1"> 228 <property stdset="1">
229 <name>name</name> 229 <name>name</name>
230 <cstring>channel7</cstring> 230 <cstring>channel7</cstring>
231 </property> 231 </property>
232 <property stdset="1"> 232 <property stdset="1">
233 <name>text</name> 233 <name>text</name>
234 <string>7</string> 234 <string>7</string>
235 </property> 235 </property>
236 </widget> 236 </widget>
237 <widget row="0" column="3" > 237 <widget row="0" column="3" >
238 <class>QCheckBox</class> 238 <class>QCheckBox</class>
239 <property stdset="1"> 239 <property stdset="1">
240 <name>name</name> 240 <name>name</name>
241 <cstring>channel3</cstring> 241 <cstring>channel3</cstring>
242 </property> 242 </property>
243 <property stdset="1"> 243 <property stdset="1">
244 <name>text</name> 244 <name>text</name>
245 <string>3</string> 245 <string>3</string>
246 </property> 246 </property>
247 </widget> 247 </widget>
248 <widget row="1" column="0" > 248 <widget row="1" column="0" >
249 <class>QCheckBox</class> 249 <class>QCheckBox</class>
250 <property stdset="1"> 250 <property stdset="1">
251 <name>name</name> 251 <name>name</name>
252 <cstring>channel5</cstring> 252 <cstring>channel5</cstring>
253 </property> 253 </property>
254 <property stdset="1"> 254 <property stdset="1">
255 <name>text</name> 255 <name>text</name>
256 <string>5</string> 256 <string>5</string>
257 </property> 257 </property>
258 </widget> 258 </widget>
259 <widget row="0" column="4" > 259 <widget row="0" column="4" >
260 <class>QCheckBox</class> 260 <class>QCheckBox</class>
261 <property stdset="1"> 261 <property stdset="1">
262 <name>name</name> 262 <name>name</name>
263 <cstring>channel4</cstring> 263 <cstring>channel4</cstring>
264 </property> 264 </property>
265 <property stdset="1"> 265 <property stdset="1">
266 <name>text</name> 266 <name>text</name>
267 <string>4</string> 267 <string>4</string>
268 </property> 268 </property>
269 </widget> 269 </widget>
270 <widget row="2" column="2" > 270 <widget row="2" column="2" >
271 <class>QCheckBox</class> 271 <class>QCheckBox</class>
272 <property stdset="1"> 272 <property stdset="1">
273 <name>name</name> 273 <name>name</name>
274 <cstring>channel12</cstring> 274 <cstring>channel12</cstring>
275 </property> 275 </property>
276 <property stdset="1"> 276 <property stdset="1">
277 <name>text</name> 277 <name>text</name>
278 <string>12</string> 278 <string>12</string>
279 </property> 279 </property>
280 </widget> 280 </widget>
281 <widget row="2" column="3" > 281 <widget row="2" column="3" >
282 <class>QCheckBox</class> 282 <class>QCheckBox</class>
283 <property stdset="1"> 283 <property stdset="1">
284 <name>name</name> 284 <name>name</name>
285 <cstring>channel13</cstring> 285 <cstring>channel13</cstring>
286 </property> 286 </property>
287 <property stdset="1"> 287 <property stdset="1">
288 <name>text</name> 288 <name>text</name>
289 <string>13</string> 289 <string>13</string>
290 </property> 290 </property>
291 </widget> 291 </widget>
292 <widget row="2" column="4" > 292 <widget row="2" column="4" >
293 <class>QCheckBox</class> 293 <class>QCheckBox</class>
294 <property stdset="1"> 294 <property stdset="1">
295 <name>name</name> 295 <name>name</name>
296 <cstring>channel14</cstring> 296 <cstring>channel14</cstring>
297 </property> 297 </property>
298 <property stdset="1"> 298 <property stdset="1">
299 <name>text</name> 299 <name>text</name>
300 <string>14</string> 300 <string>14</string>
301 </property> 301 </property>
302 </widget> 302 </widget>
303 </grid> 303 </grid>
304 </widget> 304 </widget>
305 <widget row="0" column="1" rowspan="1" colspan="3" > 305 <widget row="0" column="1" rowspan="1" colspan="3" >
306 <class>QComboBox</class> 306 <class>QComboBox</class>
307 <property stdset="1"> 307 <property stdset="1">
308 <name>name</name> 308 <name>name</name>
309 <cstring>interfaceName</cstring> 309 <cstring>interfaceName</cstring>
310 </property> 310 </property>
311 <property stdset="1"> 311 <property stdset="1">
312 <name>enabled</name> 312 <name>enabled</name>
313 <bool>true</bool> 313 <bool>true</bool>
314 </property> 314 </property>
315 <property stdset="1">
316 <name>editable</name>
317 <bool>false</bool>
318 </property>
315 <property> 319 <property>
316 <name>whatsThis</name> 320 <name>whatsThis</name>
317 <string>Choose the interface used for sniffing.</string> 321 <string>Choose the interface used for sniffing.</string>
318 </property> 322 </property>
319 </widget> 323 </widget>
320 <widget row="1" column="1" rowspan="1" colspan="3" > 324 <widget row="1" column="1" rowspan="1" colspan="3" >
321 <class>QComboBox</class> 325 <class>QComboBox</class>
322 <item> 326 <item>
323 <property> 327 <property>
324 <name>text</name> 328 <name>text</name>
325 <string>&lt;select&gt;</string> 329 <string>&lt;select&gt;</string>
326 </property> 330 </property>
327 </item> 331 </item>
328 <item> 332 <item>
329 <property> 333 <property>
330 <name>text</name> 334 <name>text</name>
331 <string>cisco</string> 335 <string>cisco</string>
332 </property> 336 </property>
333 </item> 337 </item>
334 <item> 338 <item>
335 <property> 339 <property>
336 <name>text</name> 340 <name>text</name>
337 <string>wlan-ng</string> 341 <string>wlan-ng</string>
338 </property> 342 </property>
339 </item> 343 </item>
340 <item> 344 <item>
341 <property> 345 <property>
342 <name>text</name> 346 <name>text</name>
343 <string>hostap</string> 347 <string>hostap</string>
344 </property> 348 </property>
345 </item> 349 </item>
346 <item> 350 <item>
347 <property> 351 <property>
348 <name>text</name> 352 <name>text</name>
349 <string>orinoco</string> 353 <string>orinoco</string>
350 </property> 354 </property>
351 </item> 355 </item>
352 <item> 356 <item>
353 <property> 357 <property>
354 <name>text</name> 358 <name>text</name>
355 <string>&lt;manual&gt;</string> 359 <string>&lt;manual&gt;</string>
356 </property> 360 </property>
357 </item> 361 </item>
358 <item> 362 <item>
359 <property> 363 <property>
360 <name>text</name> 364 <name>text</name>
361 <string>&lt;file&gt;</string> 365 <string>&lt;file&gt;</string>
362 </property> 366 </property>
363 </item> 367 </item>
364 <property stdset="1"> 368 <property stdset="1">
365 <name>name</name> 369 <name>name</name>
366 <cstring>deviceType</cstring> 370 <cstring>deviceType</cstring>
367 </property> 371 </property>
368 <property stdset="1"> 372 <property stdset="1">
369 <name>enabled</name> 373 <name>enabled</name>
370 <bool>true</bool> 374 <bool>true</bool>
371 </property> 375 </property>
372 <property> 376 <property>
373 <name>whatsThis</name> 377 <name>whatsThis</name>
374 <string>Choose the type of driver used for sniffing.</string> 378 <string>Choose the type of driver used for sniffing.</string>
375 </property> 379 </property>
376 </widget> 380 </widget>
377 <spacer row="3" column="0" > 381 <spacer row="3" column="0" >
378 <property> 382 <property>
379 <name>name</name> 383 <name>name</name>
380 <cstring>Spacer4</cstring> 384 <cstring>Spacer4</cstring>
381 </property> 385 </property>
382 <property stdset="1"> 386 <property stdset="1">
383 <name>orientation</name> 387 <name>orientation</name>
384 <enum>Vertical</enum> 388 <enum>Vertical</enum>
385 </property> 389 </property>
386 <property stdset="1"> 390 <property stdset="1">
387 <name>sizeType</name> 391 <name>sizeType</name>
388 <enum>Expanding</enum> 392 <enum>Expanding</enum>
389 </property> 393 </property>
390 <property> 394 <property>
391 <name>sizeHint</name> 395 <name>sizeHint</name>
392 <size> 396 <size>
393 <width>20</width> 397 <width>20</width>
394 <height>20</height> 398 <height>20</height>
395 </size> 399 </size>
396 </property> 400 </property>
397 </spacer> 401 </spacer>
398 <widget row="4" column="2" > 402 <widget row="4" column="2" >
399 <class>QLabel</class> 403 <class>QLabel</class>
400 <property stdset="1"> 404 <property stdset="1">
401 <name>name</name> 405 <name>name</name>
402 <cstring>TextLabel1</cstring> 406 <cstring>TextLabel1</cstring>
403 </property> 407 </property>
404 <property stdset="1"> 408 <property stdset="1">
405 <name>text</name> 409 <name>text</name>
406 <string>every</string> 410 <string>every</string>
407 </property> 411 </property>
408 </widget> 412 </widget>
409 <widget row="4" column="0" rowspan="1" colspan="2" > 413 <widget row="4" column="0" rowspan="1" colspan="2" >
410 <class>QCheckBox</class> 414 <class>QCheckBox</class>
411 <property stdset="1"> 415 <property stdset="1">
412 <name>name</name> 416 <name>name</name>
413 <cstring>hopChannels</cstring> 417 <cstring>hopChannels</cstring>
414 </property> 418 </property>
415 <property stdset="1"> 419 <property stdset="1">
416 <name>text</name> 420 <name>text</name>
417 <string>Hop Channels</string> 421 <string>Hop Channels</string>
418 </property> 422 </property>
419 <property stdset="1"> 423 <property stdset="1">
420 <name>checked</name> 424 <name>checked</name>
421 <bool>true</bool> 425 <bool>true</bool>
422 </property> 426 </property>
423 </widget> 427 </widget>
424 <widget row="4" column="3" > 428 <widget row="4" column="3" >
425 <class>QSpinBox</class> 429 <class>QSpinBox</class>
426 <property stdset="1"> 430 <property stdset="1">
427 <name>name</name> 431 <name>name</name>
428 <cstring>hopInterval</cstring> 432 <cstring>hopInterval</cstring>
429 </property> 433 </property>
430 <property stdset="1"> 434 <property stdset="1">
431 <name>enabled</name> 435 <name>enabled</name>
432 <bool>true</bool> 436 <bool>true</bool>
433 </property> 437 </property>
434 <property stdset="1"> 438 <property stdset="1">
435 <name>suffix</name> 439 <name>suffix</name>
436 <string> ms</string> 440 <string> ms</string>
437 </property> 441 </property>
438 <property stdset="1"> 442 <property stdset="1">
439 <name>maxValue</name> 443 <name>maxValue</name>
440 <number>2000</number> 444 <number>2000</number>
441 </property> 445 </property>
442 <property stdset="1"> 446 <property stdset="1">
443 <name>minValue</name> 447 <name>minValue</name>
444 <number>100</number> 448 <number>100</number>
445 </property> 449 </property>
446 <property stdset="1"> 450 <property stdset="1">
447 <name>lineStep</name> 451 <name>lineStep</name>
448 <number>100</number> 452 <number>100</number>
449 </property> 453 </property>
450 <property stdset="1"> 454 <property stdset="1">
451 <name>value</name> 455 <name>value</name>
452 <number>1000</number> 456 <number>1000</number>
453 </property> 457 </property>
454 <property> 458 <property>
455 <name>whatsThis</name> 459 <name>whatsThis</name>
456 <string>Choose the channel hop interval.</string> 460 <string>Choose the channel hop interval.</string>
457 </property> 461 </property>
458 </widget> 462 </widget>
459 <widget row="5" column="0" rowspan="1" colspan="4" > 463 <widget row="5" column="0" rowspan="1" colspan="4" >
460 <class>QCheckBox</class> 464 <class>QCheckBox</class>
461 <property stdset="1"> 465 <property stdset="1">
462 <name>name</name> 466 <name>name</name>
463 <cstring>adaptiveHopping</cstring> 467 <cstring>adaptiveHopping</cstring>
464 </property> 468 </property>
465 <property stdset="1"> 469 <property stdset="1">
466 <name>enabled</name> 470 <name>enabled</name>
467 <bool>false</bool> 471 <bool>false</bool>
468 </property> 472 </property>
469 <property stdset="1"> 473 <property stdset="1">
470 <name>text</name> 474 <name>text</name>
471 <string>Use Adaptive(TM) Hop Scheme</string> 475 <string>Use Adaptive(TM) Hop Scheme</string>
472 </property> 476 </property>
473 </widget> 477 </widget>
474 </grid> 478 </grid>
475 </widget> 479 </widget>
476 <widget> 480 <widget>
477 <class>QWidget</class> 481 <class>QWidget</class>
478 <property stdset="1"> 482 <property stdset="1">
479 <name>name</name> 483 <name>name</name>
480 <cstring>tab</cstring> 484 <cstring>tab</cstring>
481 </property> 485 </property>
482 <attribute> 486 <attribute>
483 <name>title</name> 487 <name>title</name>
484 <string>Capture</string> 488 <string>Capture</string>
485 </attribute> 489 </attribute>
486 <grid> 490 <grid>
487 <property stdset="1"> 491 <property stdset="1">
488 <name>margin</name> 492 <name>margin</name>
489 <number>5</number> 493 <number>5</number>
490 </property> 494 </property>
491 <property stdset="1"> 495 <property stdset="1">
492 <name>spacing</name> 496 <name>spacing</name>
493 <number>3</number> 497 <number>3</number>
494 </property> 498 </property>
495 <widget row="2" column="0" rowspan="1" colspan="3" > 499 <widget row="2" column="0" rowspan="1" colspan="3" >
496 <class>ProtocolListView</class> 500 <class>ProtocolListView</class>
497 <property stdset="1"> 501 <property stdset="1">
498 <name>name</name> 502 <name>name</name>
499 <cstring>capturePackets</cstring> 503 <cstring>capturePackets</cstring>
500 </property> 504 </property>
501 <property stdset="1"> 505 <property stdset="1">
502 <name>enabled</name> 506 <name>enabled</name>
503 <bool>false</bool> 507 <bool>false</bool>
504 </property> 508 </property>
505 <property stdset="1"> 509 <property stdset="1">
506 <name>sizePolicy</name> 510 <name>sizePolicy</name>
507 <sizepolicy> 511 <sizepolicy>
508 <hsizetype>7</hsizetype> 512 <hsizetype>7</hsizetype>
509 <vsizetype>7</vsizetype> 513 <vsizetype>7</vsizetype>
510 </sizepolicy> 514 </sizepolicy>
511 </property> 515 </property>
512 </widget> 516 </widget>
513 <widget row="1" column="0" rowspan="1" colspan="3" > 517 <widget row="1" column="0" rowspan="1" colspan="3" >
514 <class>QLineEdit</class> 518 <class>QLineEdit</class>
515 <property stdset="1"> 519 <property stdset="1">
516 <name>name</name> 520 <name>name</name>
517 <cstring>captureFileName</cstring> 521 <cstring>captureFileName</cstring>
518 </property> 522 </property>
519 <property stdset="1"> 523 <property stdset="1">
520 <name>enabled</name> 524 <name>enabled</name>
521 <bool>false</bool> 525 <bool>false</bool>
522 </property> 526 </property>
523 <property stdset="1"> 527 <property stdset="1">
524 <name>text</name> 528 <name>text</name>
525 <string>/tmp/capture</string> 529 <string>/tmp/capture</string>
526 </property> 530 </property>
527 </widget> 531 </widget>
528 <widget row="0" column="2" > 532 <widget row="0" column="2" >
529 <class>QToolButton</class> 533 <class>QToolButton</class>
530 <property stdset="1"> 534 <property stdset="1">
531 <name>name</name> 535 <name>name</name>
532 <cstring>getCaptureFileName</cstring> 536 <cstring>getCaptureFileName</cstring>
533 </property> 537 </property>
534 <property stdset="1"> 538 <property stdset="1">
535 <name>enabled</name> 539 <name>enabled</name>
536 <bool>false</bool> 540 <bool>false</bool>
537 </property> 541 </property>
538 <property stdset="1"> 542 <property stdset="1">
539 <name>text</name> 543 <name>text</name>
540 <string>Browse</string> 544 <string>Browse</string>
541 </property> 545 </property>
542 </widget> 546 </widget>
543 <spacer row="0" column="1" > 547 <spacer row="0" column="1" >
544 <property> 548 <property>
545 <name>name</name> 549 <name>name</name>
546 <cstring>Spacer2</cstring> 550 <cstring>Spacer2</cstring>
547 </property> 551 </property>
548 <property stdset="1"> 552 <property stdset="1">
549 <name>orientation</name> 553 <name>orientation</name>
550 <enum>Horizontal</enum> 554 <enum>Horizontal</enum>
551 </property> 555 </property>
552 <property stdset="1"> 556 <property stdset="1">
553 <name>sizeType</name> 557 <name>sizeType</name>
554 <enum>Expanding</enum> 558 <enum>Expanding</enum>
555 </property> 559 </property>
556 <property> 560 <property>
557 <name>sizeHint</name> 561 <name>sizeHint</name>
558 <size> 562 <size>
559 <width>20</width> 563 <width>20</width>
560 <height>20</height> 564 <height>20</height>
561 </size> 565 </size>
562 </property> 566 </property>
563 </spacer> 567 </spacer>
564 <widget row="0" column="0" > 568 <widget row="0" column="0" >
565 <class>QCheckBox</class> 569 <class>QCheckBox</class>
566 <property stdset="1"> 570 <property stdset="1">
567 <name>name</name> 571 <name>name</name>
568 <cstring>writeCaptureFile</cstring> 572 <cstring>writeCaptureFile</cstring>
569 </property> 573 </property>
570 <property stdset="1"> 574 <property stdset="1">
571 <name>enabled</name> 575 <name>enabled</name>
572 <bool>true</bool> 576 <bool>true</bool>
573 </property> 577 </property>
574 <property stdset="1"> 578 <property stdset="1">
575 <name>text</name> 579 <name>text</name>
576 <string>Write Capture Files To</string> 580 <string>Write Capture Files To</string>
577 </property> 581 </property>
578 </widget> 582 </widget>
579 </grid> 583 </grid>
580 </widget> 584 </widget>
581 <widget> 585 <widget>
582 <class>QWidget</class> 586 <class>QWidget</class>
583 <property stdset="1"> 587 <property stdset="1">
584 <name>name</name> 588 <name>name</name>
585 <cstring>tab</cstring> 589 <cstring>tab</cstring>
586 </property> 590 </property>
587 <attribute> 591 <attribute>
588 <name>title</name> 592 <name>title</name>
589 <string>Parse</string> 593 <string>Parse</string>
590 </attribute> 594 </attribute>
591 <grid> 595 <grid>
592 <property stdset="1"> 596 <property stdset="1">
593 <name>margin</name> 597 <name>margin</name>
594 <number>5</number> 598 <number>5</number>
595 </property> 599 </property>
596 <property stdset="1"> 600 <property stdset="1">
597 <name>spacing</name> 601 <name>spacing</name>
598 <number>3</number> 602 <number>3</number>
599 </property> 603 </property>
600 <widget row="0" column="0" > 604 <widget row="0" column="0" >
601 <class>ProtocolListView</class> 605 <class>ProtocolListView</class>
602 <property stdset="1"> 606 <property stdset="1">
603 <name>name</name> 607 <name>name</name>
604 <cstring>parsePackets</cstring> 608 <cstring>parsePackets</cstring>
605 </property> 609 </property>
606 <property stdset="1"> 610 <property stdset="1">
607 <name>sizePolicy</name> 611 <name>sizePolicy</name>
608 <sizepolicy> 612 <sizepolicy>
609 <hsizetype>7</hsizetype> 613 <hsizetype>7</hsizetype>
610 <vsizetype>7</vsizetype> 614 <vsizetype>7</vsizetype>
611 </sizepolicy> 615 </sizepolicy>
612 </property> 616 </property>
613 </widget> 617 </widget>
614 </grid> 618 </grid>
615 </widget> 619 </widget>
616 <widget> 620 <widget>
617 <class>QWidget</class> 621 <class>QWidget</class>
618 <property stdset="1"> 622 <property stdset="1">
619 <name>name</name> 623 <name>name</name>
620 <cstring>tab</cstring> 624 <cstring>tab</cstring>
621 </property> 625 </property>
622 <attribute> 626 <attribute>
623 <name>title</name> 627 <name>title</name>
624 <string>UI</string> 628 <string>UI</string>
625 </attribute> 629 </attribute>
626 <grid> 630 <grid>
627 <property stdset="1"> 631 <property stdset="1">
628 <name>margin</name> 632 <name>margin</name>
629 <number>11</number> 633 <number>11</number>
630 </property> 634 </property>
631 <property stdset="1"> 635 <property stdset="1">
632 <name>spacing</name> 636 <name>spacing</name>
633 <number>6</number> 637 <number>6</number>
634 </property> 638 </property>
635 <widget row="3" column="0" > 639 <widget row="3" column="0" >
636 <class>QGroupBox</class> 640 <class>QGroupBox</class>
637 <property stdset="1"> 641 <property stdset="1">
638 <name>name</name> 642 <name>name</name>
639 <cstring>GroupBox4_2</cstring> 643 <cstring>GroupBox4_2</cstring>
640 </property> 644 </property>
641 <property stdset="1"> 645 <property stdset="1">
642 <name>title</name> 646 <name>title</name>
643 <string>Action On Detecting</string> 647 <string>Action On Detecting</string>
644 </property> 648 </property>
645 <grid> 649 <grid>
646 <property stdset="1"> 650 <property stdset="1">
647 <name>margin</name> 651 <name>margin</name>
648 <number>11</number> 652 <number>11</number>
649 </property> 653 </property>
650 <property stdset="1"> 654 <property stdset="1">
651 <name>spacing</name> 655 <name>spacing</name>
652 <number>6</number> 656 <number>6</number>
653 </property> 657 </property>
654 <widget row="1" column="0" > 658 <widget row="1" column="0" >
655 <class>QLabel</class> 659 <class>QLabel</class>
656 <property stdset="1"> 660 <property stdset="1">
657 <name>name</name> 661 <name>name</name>
658 <cstring>TextLabel2</cstring> 662 <cstring>TextLabel2</cstring>
659 </property> 663 </property>
660 <property stdset="1"> 664 <property stdset="1">
661 <name>text</name> 665 <name>text</name>
662 <string>New Wireless Station</string> 666 <string>New Wireless Station</string>
663 </property> 667 </property>
664 </widget> 668 </widget>
665 <widget row="0" column="0" > 669 <widget row="0" column="0" >
666 <class>QLabel</class> 670 <class>QLabel</class>
667 <property stdset="1"> 671 <property stdset="1">
668 <name>name</name> 672 <name>name</name>
669 <cstring>TextLabel1_3</cstring> 673 <cstring>TextLabel1_3</cstring>
670 </property> 674 </property>
671 <property stdset="1"> 675 <property stdset="1">
672 <name>text</name> 676 <name>text</name>
673 <string>New Network</string> 677 <string>New Network</string>
674 </property> 678 </property>
675 </widget> 679 </widget>
676 <widget row="0" column="1" > 680 <widget row="0" column="1" >
677 <class>QComboBox</class> 681 <class>QComboBox</class>
678 <property stdset="1"> 682 <property stdset="1">
679 <name>name</name> 683 <name>name</name>
680 <cstring>newNetwork</cstring> 684 <cstring>newNetwork</cstring>
681 </property> 685 </property>
682 </widget> 686 </widget>
683 <widget row="1" column="1" > 687 <widget row="1" column="1" >
684 <class>QComboBox</class> 688 <class>QComboBox</class>
685 <property stdset="1"> 689 <property stdset="1">
686 <name>name</name> 690 <name>name</name>
687 <cstring>newWirelessStation</cstring> 691 <cstring>newWirelessStation</cstring>
688 </property> 692 </property>
689 </widget> 693 </widget>
690 <widget row="2" column="1" > 694 <widget row="2" column="1" >
691 <class>QComboBox</class> 695 <class>QComboBox</class>
692 <property stdset="1"> 696 <property stdset="1">
693 <name>name</name> 697 <name>name</name>
694 <cstring>newStation</cstring> 698 <cstring>newStation</cstring>
695 </property> 699 </property>
696 </widget> 700 </widget>
697 <widget row="2" column="0" > 701 <widget row="2" column="0" >
698 <class>QLabel</class> 702 <class>QLabel</class>
699 <property stdset="1"> 703 <property stdset="1">
700 <name>name</name> 704 <name>name</name>
701 <cstring>TextLabel3</cstring> 705 <cstring>TextLabel3</cstring>
702 </property> 706 </property>
703 <property stdset="1"> 707 <property stdset="1">
704 <name>text</name> 708 <name>text</name>
705 <string>New Station</string> 709 <string>New Station</string>
706 </property> 710 </property>
707 </widget> 711 </widget>
708 </grid> 712 </grid>
709 </widget> 713 </widget>
710 <spacer row="2" column="0" > 714 <spacer row="2" column="0" >
711 <property> 715 <property>
712 <name>name</name> 716 <name>name</name>
713 <cstring>Spacer3</cstring> 717 <cstring>Spacer3</cstring>
714 </property> 718 </property>
715 <property stdset="1"> 719 <property stdset="1">
716 <name>orientation</name> 720 <name>orientation</name>
717 <enum>Vertical</enum> 721 <enum>Vertical</enum>
718 </property> 722 </property>
719 <property stdset="1"> 723 <property stdset="1">
720 <name>sizeType</name> 724 <name>sizeType</name>
721 <enum>Expanding</enum> 725 <enum>Expanding</enum>
722 </property> 726 </property>
723 <property> 727 <property>
724 <name>sizeHint</name> 728 <name>sizeHint</name>
725 <size> 729 <size>
726 <width>20</width> 730 <width>20</width>
727 <height>20</height> 731 <height>20</height>
728 </size> 732 </size>
729 </property> 733 </property>
730 </spacer> 734 </spacer>
731 <widget row="0" column="0" > 735 <widget row="0" column="0" >
732 <class>QCheckBox</class> 736 <class>QCheckBox</class>
733 <property stdset="1"> 737 <property stdset="1">
734 <name>name</name> 738 <name>name</name>
735 <cstring>lookupVendor</cstring> 739 <cstring>lookupVendor</cstring>
736 </property> 740 </property>
737 <property stdset="1"> 741 <property stdset="1">
738 <name>text</name> 742 <name>text</name>
739 <string>Lookup MAC vendor names</string> 743 <string>Lookup MAC vendor names</string>
740 </property> 744 </property>
741 </widget> 745 </widget>
742 <widget row="1" column="0" > 746 <widget row="1" column="0" >
743 <class>QCheckBox</class> 747 <class>QCheckBox</class>
744 <property stdset="1"> 748 <property stdset="1">
745 <name>name</name> 749 <name>name</name>
746 <cstring>openTree</cstring> 750 <cstring>openTree</cstring>
747 </property> 751 </property>
748 <property stdset="1"> 752 <property stdset="1">
749 <name>text</name> 753 <name>text</name>
750 <string>Open Tree On New Station</string> 754 <string>Open Tree On New Station</string>
751 </property> 755 </property>
752 </widget> 756 </widget>
753 </grid> 757 </grid>
754 </widget> 758 </widget>
755 <widget> 759 <widget>
756 <class>QWidget</class> 760 <class>QWidget</class>
757 <property stdset="1"> 761 <property stdset="1">
758 <name>name</name> 762 <name>name</name>
759 <cstring>tab</cstring> 763 <cstring>tab</cstring>
760 </property> 764 </property>
761 <attribute> 765 <attribute>
762 <name>title</name> 766 <name>title</name>
763 <string>Intrusion</string> 767 <string>Intrusion</string>
764 </attribute> 768 </attribute>
765 <grid> 769 <grid>
766 <property stdset="1"> 770 <property stdset="1">
767 <name>margin</name> 771 <name>margin</name>
768 <number>11</number> 772 <number>11</number>
769 </property> 773 </property>
770 <property stdset="1"> 774 <property stdset="1">
771 <name>spacing</name> 775 <name>spacing</name>
772 <number>6</number> 776 <number>6</number>
773 </property> 777 </property>
774 <widget row="1" column="0" > 778 <widget row="1" column="0" >
775 <class>QGroupBox</class> 779 <class>QGroupBox</class>
776 <property stdset="1"> 780 <property stdset="1">
777 <name>name</name> 781 <name>name</name>
778 <cstring>GroupBox3</cstring> 782 <cstring>GroupBox3</cstring>
779 </property> 783 </property>
780 <property stdset="1"> 784 <property stdset="1">
781 <name>enabled</name> 785 <name>enabled</name>
782 <bool>false</bool> 786 <bool>false</bool>
783 </property> 787 </property>
784 <property stdset="1"> 788 <property stdset="1">
785 <name>title</name> 789 <name>title</name>
786 <string>Link Level</string> 790 <string>Link Level</string>
787 </property> 791 </property>
788 <grid> 792 <grid>
789 <property stdset="1"> 793 <property stdset="1">
790 <name>margin</name> 794 <name>margin</name>
791 <number>11</number> 795 <number>11</number>
792 </property> 796 </property>
793 <property stdset="1"> 797 <property stdset="1">
794 <name>spacing</name> 798 <name>spacing</name>
795 <number>6</number> 799 <number>6</number>
796 </property> 800 </property>
797 <widget row="0" column="0" > 801 <widget row="0" column="0" >
798 <class>QLabel</class> 802 <class>QLabel</class>
799 <property stdset="1"> 803 <property stdset="1">
800 <name>name</name> 804 <name>name</name>
801 <cstring>TextLabel1_5</cstring> 805 <cstring>TextLabel1_5</cstring>
802 </property> 806 </property>
803 <property stdset="1"> 807 <property stdset="1">
804 <name>text</name> 808 <name>text</name>
805 <string>Fake Mac:</string> 809 <string>Fake Mac:</string>
806 </property> 810 </property>
807 </widget> 811 </widget>
808 <widget row="1" column="0" rowspan="1" colspan="2" > 812 <widget row="1" column="0" rowspan="1" colspan="2" >
809 <class>QCheckBox</class> 813 <class>QCheckBox</class>
810 <property stdset="1"> 814 <property stdset="1">
811 <name>name</name> 815 <name>name</name>
812 <cstring>sendProbeRequests</cstring> 816 <cstring>sendProbeRequests</cstring>
813 </property> 817 </property>
814 <property stdset="1"> 818 <property stdset="1">
815 <name>text</name> 819 <name>text</name>
816 <string>Send proble requests</string> 820 <string>Send proble requests</string>
817 </property> 821 </property>
818 </widget> 822 </widget>
819 <widget row="0" column="1" > 823 <widget row="0" column="1" >
820 <class>QComboBox</class> 824 <class>QComboBox</class>
821 <item> 825 <item>
822 <property> 826 <property>
823 <name>text</name> 827 <name>text</name>
824 <string>&lt;automatic&gt;</string> 828 <string>&lt;automatic&gt;</string>
825 </property> 829 </property>
826 </item> 830 </item>
827 <item> 831 <item>
828 <property> 832 <property>
829 <name>text</name> 833 <name>text</name>
830 <string>44:44:44:44:44:44</string> 834 <string>44:44:44:44:44:44</string>
831 </property> 835 </property>
832 </item> 836 </item>
833 <property stdset="1"> 837 <property stdset="1">
834 <name>name</name> 838 <name>name</name>
835 <cstring>fakeMac</cstring> 839 <cstring>fakeMac</cstring>
836 </property> 840 </property>
837 <property stdset="1"> 841 <property stdset="1">
838 <name>sizePolicy</name> 842 <name>sizePolicy</name>
839 <sizepolicy> 843 <sizepolicy>
840 <hsizetype>7</hsizetype> 844 <hsizetype>7</hsizetype>
841 <vsizetype>0</vsizetype> 845 <vsizetype>0</vsizetype>
842 </sizepolicy> 846 </sizepolicy>
843 </property> 847 </property>
844 <property stdset="1"> 848 <property stdset="1">
845 <name>editable</name> 849 <name>editable</name>
846 <bool>true</bool> 850 <bool>true</bool>
847 </property> 851 </property>
848 <property stdset="1"> 852 <property stdset="1">
849 <name>currentItem</name> 853 <name>currentItem</name>
850 <number>1</number> 854 <number>1</number>
851 </property> 855 </property>
852 <property stdset="1"> 856 <property stdset="1">
853 <name>autoCompletion</name> 857 <name>autoCompletion</name>
854 <bool>true</bool> 858 <bool>true</bool>
855 </property> 859 </property>
856 </widget> 860 </widget>
857 <widget row="2" column="0" rowspan="1" colspan="2" > 861 <widget row="2" column="0" rowspan="1" colspan="2" >
858 <class>QCheckBox</class> 862 <class>QCheckBox</class>
859 <property stdset="1"> 863 <property stdset="1">
860 <name>name</name> 864 <name>name</name>
861 <cstring>tryToAuthenticate</cstring> 865 <cstring>tryToAuthenticate</cstring>
862 </property> 866 </property>
863 <property stdset="1"> 867 <property stdset="1">
864 <name>text</name> 868 <name>text</name>
865 <string>Try to authenticate</string> 869 <string>Try to authenticate</string>
866 </property> 870 </property>
867 </widget> 871 </widget>
868 </grid> 872 </grid>
869 </widget> 873 </widget>
870 <widget row="0" column="0" > 874 <widget row="0" column="0" >
871 <class>QCheckBox</class> 875 <class>QCheckBox</class>
872 <property stdset="1"> 876 <property stdset="1">
873 <name>name</name> 877 <name>name</name>
874 <cstring>enableActiveScanning</cstring> 878 <cstring>enableActiveScanning</cstring>
875 </property> 879 </property>
876 <property stdset="1"> 880 <property stdset="1">
877 <name>enabled</name> 881 <name>enabled</name>
878 <bool>false</bool> 882 <bool>false</bool>
879 </property> 883 </property>
880 <property stdset="1"> 884 <property stdset="1">
881 <name>text</name> 885 <name>text</name>
882 <string>Enable active scanning</string> 886 <string>Enable active scanning</string>
883 </property> 887 </property>
884 </widget> 888 </widget>
885 <widget row="2" column="0" > 889 <widget row="2" column="0" >
886 <class>QGroupBox</class> 890 <class>QGroupBox</class>
887 <property stdset="1"> 891 <property stdset="1">
888 <name>name</name> 892 <name>name</name>
889 <cstring>GroupBox4</cstring> 893 <cstring>GroupBox4</cstring>
890 </property> 894 </property>
891 <property stdset="1"> 895 <property stdset="1">
892 <name>enabled</name> 896 <name>enabled</name>
893 <bool>false</bool> 897 <bool>false</bool>
894 </property> 898 </property>
895 <property stdset="1"> 899 <property stdset="1">
896 <name>title</name> 900 <name>title</name>
897 <string>IP Level</string> 901 <string>IP Level</string>
898 </property> 902 </property>
899 <grid> 903 <grid>
900 <property stdset="1"> 904 <property stdset="1">
901 <name>margin</name> 905 <name>margin</name>
902 <number>11</number> 906 <number>11</number>
903 </property> 907 </property>
904 <property stdset="1"> 908 <property stdset="1">
905 <name>spacing</name> 909 <name>spacing</name>
906 <number>6</number> 910 <number>6</number>
907 </property> 911 </property>
908 <widget row="1" column="0" rowspan="1" colspan="2" > 912 <widget row="1" column="0" rowspan="1" colspan="2" >
909 <class>QCheckBox</class> 913 <class>QCheckBox</class>
910 <property stdset="1"> 914 <property stdset="1">
911 <name>name</name> 915 <name>name</name>
912 <cstring>CheckBox24</cstring> 916 <cstring>CheckBox24</cstring>
913 </property> 917 </property>
914 <property stdset="1"> 918 <property stdset="1">
915 <name>text</name> 919 <name>text</name>
916 <string>Request DHCP Address</string> 920 <string>Request DHCP Address</string>
917 </property> 921 </property>
918 </widget> 922 </widget>
919 <widget row="0" column="0" > 923 <widget row="0" column="0" >
920 <class>QLabel</class> 924 <class>QLabel</class>
921 <property stdset="1"> 925 <property stdset="1">
922 <name>name</name> 926 <name>name</name>
923 <cstring>TextLabel1_5_2</cstring> 927 <cstring>TextLabel1_5_2</cstring>
924 </property> 928 </property>
925 <property stdset="1"> 929 <property stdset="1">
926 <name>text</name> 930 <name>text</name>
927 <string>Fake IP:</string> 931 <string>Fake IP:</string>
928 </property> 932 </property>
929 </widget> 933 </widget>
930 <widget row="0" column="1" > 934 <widget row="0" column="1" >
931 <class>QComboBox</class> 935 <class>QComboBox</class>
932 <item> 936 <item>
933 <property> 937 <property>
934 <name>text</name> 938 <name>text</name>
935 <string>192.168.125.1</string> 939 <string>192.168.125.1</string>
936 </property> 940 </property>
937 </item> 941 </item>
938 <item> 942 <item>
939 <property> 943 <property>
940 <name>text</name> 944 <name>text</name>
941 <string>&lt;automatic&gt;</string> 945 <string>&lt;automatic&gt;</string>
942 </property> 946 </property>
943 </item> 947 </item>
944 <property stdset="1"> 948 <property stdset="1">
945 <name>name</name> 949 <name>name</name>
946 <cstring>fakeIP</cstring> 950 <cstring>fakeIP</cstring>
947 </property> 951 </property>
948 <property stdset="1"> 952 <property stdset="1">
949 <name>sizePolicy</name> 953 <name>sizePolicy</name>
950 <sizepolicy> 954 <sizepolicy>
951 <hsizetype>7</hsizetype> 955 <hsizetype>7</hsizetype>
952 <vsizetype>0</vsizetype> 956 <vsizetype>0</vsizetype>
953 </sizepolicy> 957 </sizepolicy>
954 </property> 958 </property>
955 <property stdset="1"> 959 <property stdset="1">
956 <name>editable</name> 960 <name>editable</name>
957 <bool>true</bool> 961 <bool>true</bool>
958 </property> 962 </property>
959 <property stdset="1"> 963 <property stdset="1">
960 <name>currentItem</name> 964 <name>currentItem</name>
961 <number>0</number> 965 <number>0</number>
962 </property> 966 </property>
963 </widget> 967 </widget>
964 </grid> 968 </grid>
965 </widget> 969 </widget>
966 </grid> 970 </grid>
967 </widget> 971 </widget>
968 <widget> 972 <widget>
969 <class>QWidget</class> 973 <class>QWidget</class>
970 <property stdset="1"> 974 <property stdset="1">
971 <name>name</name> 975 <name>name</name>
972 <cstring>tab</cstring> 976 <cstring>tab</cstring>
973 </property> 977 </property>
974 <attribute> 978 <attribute>
975 <name>title</name> 979 <name>title</name>
976 <string>GPS</string> 980 <string>GPS</string>
977 </attribute> 981 </attribute>
978 <widget> 982 <widget>
979 <class>QLayoutWidget</class> 983 <class>QLayoutWidget</class>
980 <property stdset="1"> 984 <property stdset="1">
981 <name>name</name> 985 <name>name</name>
982 <cstring>Layout1</cstring> 986 <cstring>Layout1</cstring>
983 </property> 987 </property>
984 <property stdset="1"> 988 <property stdset="1">
985 <name>geometry</name> 989 <name>geometry</name>
986 <rect> 990 <rect>
987 <x>10</x> 991 <x>10</x>
988 <y>40</y> 992 <y>40</y>
989 <width>216</width> 993 <width>216</width>
990 <height>27</height> 994 <height>27</height>
991 </rect> 995 </rect>
992 </property> 996 </property>
993 <hbox> 997 <hbox>
994 <property stdset="1"> 998 <property stdset="1">
995 <name>margin</name> 999 <name>margin</name>
996 <number>0</number> 1000 <number>0</number>
997 </property> 1001 </property>
998 <property stdset="1"> 1002 <property stdset="1">
999 <name>spacing</name> 1003 <name>spacing</name>
1000 <number>6</number> 1004 <number>6</number>
1001 </property> 1005 </property>
1002 <widget> 1006 <widget>
1003 <class>QLabel</class> 1007 <class>QLabel</class>
1004 <property stdset="1"> 1008 <property stdset="1">
1005 <name>name</name> 1009 <name>name</name>
1006 <cstring>TextLabel1_4</cstring> 1010 <cstring>TextLabel1_4</cstring>
1007 </property> 1011 </property>
1008 <property stdset="1"> 1012 <property stdset="1">
1009 <name>text</name> 1013 <name>text</name>
1010 <string>Host</string> 1014 <string>Host</string>
1011 </property> 1015 </property>
1012 </widget> 1016 </widget>
1013 <widget> 1017 <widget>
1014 <class>QComboBox</class> 1018 <class>QComboBox</class>
1015 <item> 1019 <item>
1016 <property> 1020 <property>
1017 <name>text</name> 1021 <name>text</name>
1018 <string>localhost</string> 1022 <string>localhost</string>
1019 </property> 1023 </property>
1020 </item> 1024 </item>
1021 <property stdset="1"> 1025 <property stdset="1">
1022 <name>name</name> 1026 <name>name</name>
1023 <cstring>ComboBox8</cstring> 1027 <cstring>gpsdHost</cstring>
1024 </property> 1028 </property>
1025 <property stdset="1"> 1029 <property stdset="1">
1026 <name>enabled</name> 1030 <name>enabled</name>
1027 <bool>false</bool> 1031 <bool>false</bool>
1028 </property> 1032 </property>
1029 <property stdset="1"> 1033 <property stdset="1">
1030 <name>editable</name> 1034 <name>editable</name>
1031 <bool>true</bool> 1035 <bool>true</bool>
1032 </property> 1036 </property>
1033 <property stdset="1"> 1037 <property stdset="1">
1034 <name>currentItem</name> 1038 <name>currentItem</name>
1035 <number>0</number> 1039 <number>0</number>
1036 </property> 1040 </property>
1037 </widget> 1041 </widget>
1038 <widget> 1042 <widget>
1039 <class>QLabel</class> 1043 <class>QLabel</class>
1040 <property stdset="1"> 1044 <property stdset="1">
1041 <name>name</name> 1045 <name>name</name>
1042 <cstring>TextLabel2_2</cstring> 1046 <cstring>TextLabel2_2</cstring>
1043 </property> 1047 </property>
1044 <property stdset="1"> 1048 <property stdset="1">
1045 <name>text</name> 1049 <name>text</name>
1046 <string>:</string> 1050 <string>:</string>
1047 </property> 1051 </property>
1048 </widget> 1052 </widget>
1049 <widget> 1053 <widget>
1050 <class>QSpinBox</class> 1054 <class>QSpinBox</class>
1051 <property stdset="1"> 1055 <property stdset="1">
1052 <name>name</name> 1056 <name>name</name>
1053 <cstring>SpinBox2</cstring> 1057 <cstring>gpsdPort</cstring>
1054 </property> 1058 </property>
1055 <property stdset="1"> 1059 <property stdset="1">
1056 <name>enabled</name> 1060 <name>enabled</name>
1057 <bool>false</bool> 1061 <bool>false</bool>
1058 </property> 1062 </property>
1059 <property stdset="1"> 1063 <property stdset="1">
1060 <name>maxValue</name> 1064 <name>maxValue</name>
1061 <number>65535</number> 1065 <number>65535</number>
1062 </property> 1066 </property>
1063 <property stdset="1"> 1067 <property stdset="1">
1064 <name>minValue</name> 1068 <name>minValue</name>
1065 <number>1024</number> 1069 <number>1024</number>
1066 </property> 1070 </property>
1067 <property stdset="1"> 1071 <property stdset="1">
1068 <name>value</name> 1072 <name>value</name>
1069 <number>2947</number> 1073 <number>2947</number>
1070 </property> 1074 </property>
1071 </widget> 1075 </widget>
1072 </hbox> 1076 </hbox>
1073 </widget> 1077 </widget>
1074 <widget> 1078 <widget>
1075 <class>QCheckBox</class> 1079 <class>QLineEdit</class>
1076 <property stdset="1"> 1080 <property stdset="1">
1077 <name>name</name> 1081 <name>name</name>
1078 <cstring>enableGPS</cstring> 1082 <cstring>commandGPS</cstring>
1083 </property>
1084 <property stdset="1">
1085 <name>enabled</name>
1086 <bool>false</bool>
1079 </property> 1087 </property>
1080 <property stdset="1"> 1088 <property stdset="1">
1081 <name>geometry</name> 1089 <name>geometry</name>
1082 <rect> 1090 <rect>
1083 <x>10</x> 1091 <x>10</x>
1084 <y>10</y> 1092 <y>110</y>
1085 <width>199</width> 1093 <width>210</width>
1086 <height>21</height> 1094 <height>22</height>
1087 </rect> 1095 </rect>
1088 </property> 1096 </property>
1089 <property stdset="1"> 1097 <property stdset="1">
1090 <name>text</name> 1098 <name>text</name>
1091 <string>Enable GPS logging w/ gpsd</string> 1099 <string>gpsd -p /dev/ttyS3 -s 57600</string>
1092 </property> 1100 </property>
1093 </widget> 1101 </widget>
1094 <widget> 1102 <widget>
1095 <class>QCheckBox</class> 1103 <class>QCheckBox</class>
1096 <property stdset="1"> 1104 <property stdset="1">
1097 <name>name</name> 1105 <name>name</name>
1098 <cstring>startGPS</cstring> 1106 <cstring>enableGPS</cstring>
1099 </property> 1107 </property>
1100 <property stdset="1"> 1108 <property stdset="1">
1101 <name>geometry</name> 1109 <name>geometry</name>
1102 <rect> 1110 <rect>
1103 <x>10</x> 1111 <x>10</x>
1104 <y>80</y> 1112 <y>10</y>
1105 <width>171</width> 1113 <width>199</width>
1106 <height>21</height> 1114 <height>21</height>
1107 </rect> 1115 </rect>
1108 </property> 1116 </property>
1109 <property stdset="1"> 1117 <property stdset="1">
1110 <name>text</name> 1118 <name>text</name>
1111 <string>Start gpsd on localhost</string> 1119 <string>Enable GPS logging w/ gpsd</string>
1112 </property> 1120 </property>
1113 </widget> 1121 </widget>
1114 <widget> 1122 <widget>
1115 <class>QLineEdit</class> 1123 <class>QCheckBox</class>
1116 <property stdset="1"> 1124 <property stdset="1">
1117 <name>name</name> 1125 <name>name</name>
1118 <cstring>commandGPS</cstring> 1126 <cstring>startGPS</cstring>
1119 </property>
1120 <property stdset="1">
1121 <name>enabled</name>
1122 <bool>false</bool>
1123 </property> 1127 </property>
1124 <property stdset="1"> 1128 <property stdset="1">
1125 <name>geometry</name> 1129 <name>geometry</name>
1126 <rect> 1130 <rect>
1127 <x>10</x> 1131 <x>10</x>
1128 <y>110</y> 1132 <y>80</y>
1129 <width>210</width> 1133 <width>171</width>
1130 <height>22</height> 1134 <height>21</height>
1131 </rect> 1135 </rect>
1132 </property> 1136 </property>
1133 <property stdset="1"> 1137 <property stdset="1">
1134 <name>text</name> 1138 <name>text</name>
1135 <string>gpsd -p /dev/ttyS3 -s 57600</string> 1139 <string>Start gpsd on localhost</string>
1136 </property> 1140 </property>
1137 </widget> 1141 </widget>
1138 </widget> 1142 </widget>
1139 </widget> 1143 </widget>
1140 </grid> 1144 </grid>
1141</widget> 1145</widget>
1142<customwidgets> 1146<customwidgets>
1143 <customwidget> 1147 <customwidget>
1144 <class>ProtocolListView</class> 1148 <class>ProtocolListView</class>
1145 <header location="local">protolistview.h</header> 1149 <header location="local">protolistview.h</header>
1146 <sizehint> 1150 <sizehint>
1147 <width>100</width> 1151 <width>100</width>
1148 <height>100</height> 1152 <height>100</height>
1149 </sizehint> 1153 </sizehint>
1150 <container>0</container> 1154 <container>0</container>
1151 <sizepolicy> 1155 <sizepolicy>
1152 <hordata>3</hordata> 1156 <hordata>3</hordata>
1153 <verdata>3</verdata> 1157 <verdata>3</verdata>
1154 </sizepolicy> 1158 </sizepolicy>
1155 <pixmap>image0</pixmap> 1159 <pixmap>image0</pixmap>
1156 </customwidget> 1160 </customwidget>
1157</customwidgets> 1161</customwidgets>
1158<images> 1162<images>
1159 <image> 1163 <image>
1160 <name>image0</name> 1164 <name>image0</name>
1161 <data format="XPM.GZ" length="646">789c6dd2c10ac2300c00d07bbf2234b7229d1be245fc04c5a3201e4615f430059d0711ff5ddb2e6bb236ec90eed134cb5a19d8ef36602af5ecdbfeeac05dda0798d3abebde87e3faa374d3807fa0d633a52d38d8de6f679fe33fc776e196f53cd010188256a3600a292882096246517815ca99884606e18044a3a40d91824820924265a7923a2e8bcd05f33db1173e002913175f2a6be6d3294871a2d95fa00e8a94ee017b69d339d90df1e77c57ea072ede6758</data> 1165 <data format="XPM.GZ" length="646">789c6dd2c10ac2300c00d07bbf2234b7229d1be245fc04c5a3201e4615f430059d0711ff5ddb2e6bb236ec90eed134cb5a19d8ef36602af5ecdbfeeac05dda0798d3abebde87e3faa374d3807fa0d633a52d38d8de6f679fe33fc776e196f53cd010188256a3600a292882096246517815ca99884606e18044a3a40d91824820924265a7923a2e8bcd05f33db1173e002913175f2a6be6d3294871a2d95fa00e8a94ee017b69d339d90df1e77c57ea072ede6758</data>
1162 </image> 1166 </image>
1163</images> 1167</images>
1164<connections> 1168<connections>
1165 <connection> 1169 <connection>
1166 <sender>hopChannels</sender> 1170 <sender>hopChannels</sender>
1167 <signal>toggled(bool)</signal> 1171 <signal>toggled(bool)</signal>
1168 <receiver>hopInterval</receiver> 1172 <receiver>hopInterval</receiver>
1169 <slot>setEnabled(bool)</slot> 1173 <slot>setEnabled(bool)</slot>
1170 </connection> 1174 </connection>
1171 <connection> 1175 <connection>
1172 <sender>hopChannels</sender> 1176 <sender>hopChannels</sender>
1173 <signal>toggled(bool)</signal> 1177 <signal>toggled(bool)</signal>
1174 <receiver>TextLabel1</receiver> 1178 <receiver>TextLabel1</receiver>
1175 <slot>setEnabled(bool)</slot> 1179 <slot>setEnabled(bool)</slot>
1176 </connection> 1180 </connection>
1177 <connection> 1181 <connection>
1178 <sender>enableActiveScanning</sender> 1182 <sender>enableActiveScanning</sender>
1179 <signal>toggled(bool)</signal> 1183 <signal>toggled(bool)</signal>
1180 <receiver>GroupBox3</receiver> 1184 <receiver>GroupBox3</receiver>
1181 <slot>setEnabled(bool)</slot> 1185 <slot>setEnabled(bool)</slot>
1182 </connection> 1186 </connection>
1183 <connection> 1187 <connection>
1184 <sender>enableActiveScanning</sender> 1188 <sender>enableActiveScanning</sender>
1185 <signal>toggled(bool)</signal> 1189 <signal>toggled(bool)</signal>
1186 <receiver>GroupBox4</receiver> 1190 <receiver>GroupBox4</receiver>
1187 <slot>setEnabled(bool)</slot> 1191 <slot>setEnabled(bool)</slot>
1188 </connection> 1192 </connection>
1189 <connection> 1193 <connection>
1190 <sender>writeCaptureFile</sender> 1194 <sender>writeCaptureFile</sender>
1191 <signal>toggled(bool)</signal> 1195 <signal>toggled(bool)</signal>
1192 <receiver>getCaptureFileName</receiver> 1196 <receiver>getCaptureFileName</receiver>
1193 <slot>setEnabled(bool)</slot> 1197 <slot>setEnabled(bool)</slot>
1194 </connection> 1198 </connection>
1195 <connection> 1199 <connection>
1196 <sender>writeCaptureFile</sender> 1200 <sender>writeCaptureFile</sender>
1197 <signal>toggled(bool)</signal> 1201 <signal>toggled(bool)</signal>
1198 <receiver>captureFileName</receiver> 1202 <receiver>captureFileName</receiver>
1199 <slot>setEnabled(bool)</slot> 1203 <slot>setEnabled(bool)</slot>
1200 </connection> 1204 </connection>
1201 <connection> 1205 <connection>
1202 <sender>writeCaptureFile</sender> 1206 <sender>writeCaptureFile</sender>
1203 <signal>toggled(bool)</signal> 1207 <signal>toggled(bool)</signal>
1204 <receiver>capturePackets</receiver> 1208 <receiver>capturePackets</receiver>
1205 <slot>setEnabled(bool)</slot> 1209 <slot>setEnabled(bool)</slot>
1206 </connection> 1210 </connection>
1207 <connection> 1211 <connection>
1208 <sender>enableGPS</sender> 1212 <sender>enableGPS</sender>
1209 <signal>toggled(bool)</signal> 1213 <signal>toggled(bool)</signal>
1210 <receiver>ComboBox8</receiver> 1214 <receiver>gpsdHost</receiver>
1211 <slot>setEnabled(bool)</slot> 1215 <slot>setEnabled(bool)</slot>
1212 </connection> 1216 </connection>
1213 <connection> 1217 <connection>
1214 <sender>enableGPS</sender> 1218 <sender>enableGPS</sender>
1215 <signal>toggled(bool)</signal> 1219 <signal>toggled(bool)</signal>
1216 <receiver>SpinBox2</receiver> 1220 <receiver>gpsdPort</receiver>
1217 <slot>setEnabled(bool)</slot> 1221 <slot>setEnabled(bool)</slot>
1218 </connection> 1222 </connection>
1219 <connection> 1223 <connection>
1220 <sender>startGPS</sender> 1224 <sender>startGPS</sender>
1221 <signal>toggled(bool)</signal> 1225 <signal>toggled(bool)</signal>
1222 <receiver>commandGPS</receiver> 1226 <receiver>commandGPS</receiver>
1223 <slot>setEnabled(bool)</slot> 1227 <slot>setEnabled(bool)</slot>
1224 </connection> 1228 </connection>
1225</connections> 1229</connections>
1226</UI> 1230</UI>
diff --git a/noncore/net/wellenreiter/gui/configwindow.cpp b/noncore/net/wellenreiter/gui/configwindow.cpp
index 11394d7..a331925 100644
--- a/noncore/net/wellenreiter/gui/configwindow.cpp
+++ b/noncore/net/wellenreiter/gui/configwindow.cpp
@@ -1,192 +1,210 @@
1/********************************************************************** 1/**********************************************************************
2** Copyright (C) 2002 Michael 'Mickey' Lauer. All rights reserved. 2** Copyright (C) 2002 Michael 'Mickey' Lauer. All rights reserved.
3** 3**
4** This file is part of Opie Environment. 4** This file is part of Opie Environment.
5** 5**
6** This file may be distributed and/or modified under the terms of the 6** This file may be distributed and/or modified under the terms of the
7** GNU General Public License version 2 as published by the Free Software 7** GNU General Public License version 2 as published by the Free Software
8** Foundation and appearing in the file LICENSE.GPL included in the 8** Foundation and appearing in the file LICENSE.GPL included in the
9** packaging of this file. 9** packaging of this file.
10** 10**
11** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE 11** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
12** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. 12** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
13** 13**
14**********************************************************************/ 14**********************************************************************/
15 15
16/* LOCAL */ 16/* LOCAL */
17#include "configwindow.h" 17#include "configwindow.h"
18#include "mainwindow.h" 18#include "mainwindow.h"
19 19
20/* QT */ 20/* QT */
21#include <qapplication.h> 21#include <qapplication.h>
22#include <qcheckbox.h> 22#include <qcheckbox.h>
23#include <qcombobox.h> 23#include <qcombobox.h>
24#include <qfile.h> 24#include <qfile.h>
25#include <qlineedit.h> 25#include <qlineedit.h>
26#include <qlayout.h> 26#include <qlayout.h>
27#include <qmap.h> 27#include <qmap.h>
28#include <qpushbutton.h> 28#include <qpushbutton.h>
29#include <qtoolbutton.h> 29#include <qtoolbutton.h>
30#include <qspinbox.h> 30#include <qspinbox.h>
31#include <qtextstream.h> 31#include <qtextstream.h>
32 32
33/* OPIE */ 33/* OPIE */
34#include <opie2/onetwork.h> 34#include <opie2/onetwork.h>
35 35
36WellenreiterConfigWindow* WellenreiterConfigWindow::_instance = 0; 36WellenreiterConfigWindow* WellenreiterConfigWindow::_instance = 0;
37 37
38WellenreiterConfigWindow::WellenreiterConfigWindow( QWidget * parent, const char * name, WFlags f ) 38WellenreiterConfigWindow::WellenreiterConfigWindow( QWidget * parent, const char * name, WFlags f )
39 :WellenreiterConfigBase( parent, name, true, f ) 39 :WellenreiterConfigBase( parent, name, true, f )
40{ 40{
41 _devicetype[ "cisco" ] = DEVTYPE_CISCO; 41 _devicetype[ "cisco" ] = DEVTYPE_CISCO;
42 _devicetype[ "wlan-ng" ] = DEVTYPE_WLAN_NG; 42 _devicetype[ "wlan-ng" ] = DEVTYPE_WLAN_NG;
43 _devicetype[ "hostap" ] = DEVTYPE_HOSTAP; 43 _devicetype[ "hostap" ] = DEVTYPE_HOSTAP;
44 _devicetype[ "orinoco" ] = DEVTYPE_ORINOCO; 44 _devicetype[ "orinoco" ] = DEVTYPE_ORINOCO;
45 _devicetype[ "<manual>" ] = DEVTYPE_MANUAL; 45 _devicetype[ "<manual>" ] = DEVTYPE_MANUAL;
46 _devicetype[ "<file>" ] = DEVTYPE_FILE; 46 _devicetype[ "<file>" ] = DEVTYPE_FILE;
47 47
48 // gather possible interface names from ONetwork 48 // gather possible interface names from ONetwork
49 ONetwork* net = ONetwork::instance(); 49 ONetwork* net = ONetwork::instance();
50 ONetwork::InterfaceIterator it = net->iterator(); 50 ONetwork::InterfaceIterator it = net->iterator();
51 while ( it.current() ) 51 while ( it.current() )
52 { 52 {
53 if ( it.current()->isWireless() ) 53 if ( it.current()->isWireless() )
54 interfaceName->insertItem( it.current()->name() ); 54 interfaceName->insertItem( it.current()->name() );
55 ++it; 55 ++it;
56 } 56 }
57 57
58 // try to guess device type 58 // try to guess device type
59 QFile m( "/proc/modules" ); 59 QFile m( "/proc/modules" );
60 if ( m.open( IO_ReadOnly ) ) 60 if ( m.open( IO_ReadOnly ) )
61 { 61 {
62 int devicetype(0); 62 int devicetype(0);
63 QString line; 63 QString line;
64 QTextStream modules( &m ); 64 QTextStream modules( &m );
65 while( !modules.atEnd() && !devicetype ) 65 while( !modules.atEnd() && !devicetype )
66 { 66 {
67 modules >> line; 67 modules >> line;
68 if ( line.contains( "cisco" ) ) devicetype = DEVTYPE_CISCO; 68 if ( line.contains( "cisco" ) ) devicetype = DEVTYPE_CISCO;
69 else if ( line.contains( "hostap" ) ) devicetype = DEVTYPE_HOSTAP; 69 else if ( line.contains( "hostap" ) ) devicetype = DEVTYPE_HOSTAP;
70 else if ( line.contains( "prism" ) ) devicetype = DEVTYPE_WLAN_NG; 70 else if ( line.contains( "prism" ) ) devicetype = DEVTYPE_WLAN_NG;
71 else if ( line.contains( "orinoco" ) ) devicetype = DEVTYPE_ORINOCO; 71 else if ( line.contains( "orinoco" ) ) devicetype = DEVTYPE_ORINOCO;
72 } 72 }
73 if ( devicetype ) 73 if ( devicetype )
74 { 74 {
75 deviceType->setCurrentItem( devicetype ); 75 deviceType->setCurrentItem( devicetype );
76 _guess = devicetype; 76 _guess = devicetype;
77 qDebug( "Wellenreiter: guessed device type to be #%d", devicetype ); 77 qDebug( "Wellenreiter: guessed device type to be #%d", devicetype );
78 } 78 }
79 } 79 }
80 80
81 #ifdef Q_WS_X11 // We're on X11: adding an Ok-Button for the Dialog here 81 #ifdef Q_WS_X11 // We're on X11: adding an Ok-Button for the Dialog here
82 QPushButton* okButton = new QPushButton( "ok", this ); 82 QPushButton* okButton = new QPushButton( "ok", this );
83 okButton->show(); 83 okButton->show();
84 WellenreiterConfigBaseLayout->addWidget( okButton, 0, 3 ); //FIXME: rename this in configbase.ui 84 WellenreiterConfigBaseLayout->addWidget( okButton, 0, 3 ); //FIXME: rename this in configbase.ui
85 connect( okButton, SIGNAL( clicked() ), this, SLOT( accept() ) ); 85 connect( okButton, SIGNAL( clicked() ), this, SLOT( accept() ) );
86 #endif 86 #endif
87 87
88 WellenreiterConfigWindow::_instance = this; 88 WellenreiterConfigWindow::_instance = this;
89 89
90 connect( deviceType, SIGNAL( activated(int) ), this, SLOT( changedDeviceType(int) ) ); 90 connect( deviceType, SIGNAL( activated(int) ), this, SLOT( changedDeviceType(int) ) );
91 connect( getCaptureFileName, SIGNAL( clicked() ), this, SLOT( getCaptureFileNameClicked() ) ); 91 connect( getCaptureFileName, SIGNAL( clicked() ), this, SLOT( getCaptureFileNameClicked() ) );
92 92
93 // make the checkbox 'channelAll' control all other channels 93 // make the checkbox 'channelAll' control all other channels
94 connect( channelAll, SIGNAL( stateChanged(int) ), this, SLOT( channelAllClicked(int) ) ); 94 connect( channelAll, SIGNAL( stateChanged(int) ), this, SLOT( channelAllClicked(int) ) );
95}; 95};
96 96
97 97
98int WellenreiterConfigWindow::driverType() const 98int WellenreiterConfigWindow::driverType() const
99{ 99{
100 QString name = deviceType->currentText(); 100 QString name = deviceType->currentText();
101 if ( _devicetype.contains( name ) ) 101 if ( _devicetype.contains( name ) )
102 { 102 {
103 return _devicetype[name]; 103 return _devicetype[name];
104 } 104 }
105 else 105 else
106 { 106 {
107 return 0; 107 return 0;
108 } 108 }
109}; 109};
110 110
111 111
112int WellenreiterConfigWindow::hoppingInterval() const 112int WellenreiterConfigWindow::hoppingInterval() const
113{ 113{
114 return hopInterval->cleanText().toInt(); 114 return hopInterval->cleanText().toInt();
115} 115}
116 116
117 117
118bool WellenreiterConfigWindow::usePrismHeader() const 118bool WellenreiterConfigWindow::usePrismHeader() const
119{ 119{
120 return prismHeader->isOn(); 120 return prismHeader->isOn();
121} 121}
122 122
123 123
124bool WellenreiterConfigWindow::isChannelChecked( int channel ) const 124bool WellenreiterConfigWindow::isChannelChecked( int channel ) const
125{ 125{
126 switch ( channel ) 126 switch ( channel )
127 { 127 {
128 case 1: return channel1->isOn(); 128 case 1: return channel1->isOn();
129 case 2: return channel2->isOn(); 129 case 2: return channel2->isOn();
130 case 3: return channel3->isOn(); 130 case 3: return channel3->isOn();
131 case 4: return channel4->isOn(); 131 case 4: return channel4->isOn();
132 case 5: return channel5->isOn(); 132 case 5: return channel5->isOn();
133 case 6: return channel6->isOn(); 133 case 6: return channel6->isOn();
134 case 7: return channel7->isOn(); 134 case 7: return channel7->isOn();
135 case 8: return channel8->isOn(); 135 case 8: return channel8->isOn();
136 case 9: return channel9->isOn(); 136 case 9: return channel9->isOn();
137 case 10: return channel10->isOn(); 137 case 10: return channel10->isOn();
138 case 11: return channel11->isOn(); 138 case 11: return channel11->isOn();
139 case 12: return channel12->isOn(); 139 case 12: return channel12->isOn();
140 case 13: return channel13->isOn(); 140 case 13: return channel13->isOn();
141 case 14: return channel14->isOn(); 141 case 14: return channel14->isOn();
142 } 142 }
143} 143}
144 144
145 145
146void WellenreiterConfigWindow::changedDeviceType(int t) 146void WellenreiterConfigWindow::changedDeviceType(int t)
147{ 147{
148 if ( t != DEVTYPE_FILE ) return; 148 if ( t != DEVTYPE_FILE ) return;
149 QString name = ( (WellenreiterMainWindow*) qApp->mainWidget() )->getFileName(false); 149 QString name = ( (WellenreiterMainWindow*) qApp->mainWidget() )->getFileName(false);
150 if ( !name.isEmpty() && QFile::exists( name ) ) 150 if ( !name.isEmpty() && QFile::exists( name ) )
151 { 151 {
152 interfaceName->insertItem( name ); 152 interfaceName->insertItem( name );
153 interfaceName->setCurrentItem( interfaceName->count()-1 ); 153 interfaceName->setCurrentItem( interfaceName->count()-1 );
154 } 154 }
155 else 155 else
156 { 156 {
157 deviceType->setCurrentItem( _guess ); 157 deviceType->setCurrentItem( _guess );
158 } 158 }
159 159
160} 160}
161 161
162 162
163void WellenreiterConfigWindow::getCaptureFileNameClicked() 163void WellenreiterConfigWindow::getCaptureFileNameClicked()
164{ 164{
165 QString name = ( (WellenreiterMainWindow*) qApp->mainWidget() )->getFileName(true); 165 QString name = ( (WellenreiterMainWindow*) qApp->mainWidget() )->getFileName(true);
166 qDebug( "name = %s", (const char*) name ); 166 qDebug( "name = %s", (const char*) name );
167 if ( !name.isEmpty() ) 167 if ( !name.isEmpty() )
168 { 168 {
169 captureFileName->setText( name ); 169 captureFileName->setText( name );
170 } 170 }
171} 171}
172 172
173 173
174void WellenreiterConfigWindow::channelAllClicked(int state) 174void WellenreiterConfigWindow::channelAllClicked(int state)
175{ 175{
176 bool b = state; 176 bool b = state;
177 channel1->setChecked( b ); 177 channel1->setChecked( b );
178 channel2->setChecked( b ); 178 channel2->setChecked( b );
179 channel3->setChecked( b ); 179 channel3->setChecked( b );
180 channel4->setChecked( b ); 180 channel4->setChecked( b );
181 channel5->setChecked( b ); 181 channel5->setChecked( b );
182 channel6->setChecked( b ); 182 channel6->setChecked( b );
183 channel7->setChecked( b ); 183 channel7->setChecked( b );
184 channel8->setChecked( b ); 184 channel8->setChecked( b );
185 channel9->setChecked( b ); 185 channel9->setChecked( b );
186 channel10->setChecked( b ); 186 channel10->setChecked( b );
187 channel11->setChecked( b ); 187 channel11->setChecked( b );
188 channel12->setChecked( b ); 188 channel12->setChecked( b );
189 channel13->setChecked( b ); 189 channel13->setChecked( b );
190 channel14->setChecked( b ); 190 channel14->setChecked( b );
191} 191}
192 192
193
194bool WellenreiterConfigWindow::useGPS() const
195{
196 return enableGPS->isChecked();
197}
198
199
200const QString WellenreiterConfigWindow::gpsHost() const
201{
202 return useGPS() ? gpsdHost->currentText() : QString::null;
203}
204
205
206int WellenreiterConfigWindow::gpsPort() const
207{
208 bool ok;
209 return useGPS() ? gpsdPort->value() : -1;
210}
diff --git a/noncore/net/wellenreiter/gui/configwindow.h b/noncore/net/wellenreiter/gui/configwindow.h
index 32dc840..8f160b1 100644
--- a/noncore/net/wellenreiter/gui/configwindow.h
+++ b/noncore/net/wellenreiter/gui/configwindow.h
@@ -1,62 +1,66 @@
1/********************************************************************** 1/**********************************************************************
2** Copyright (C) 2002 Michael 'Mickey' Lauer. All rights reserved. 2** Copyright (C) 2002 Michael 'Mickey' Lauer. All rights reserved.
3** 3**
4** This file is part of Opie Environment. 4** This file is part of Opie Environment.
5** 5**
6** This file may be distributed and/or modified under the terms of the 6** This file may be distributed and/or modified under the terms of the
7** GNU General Public License version 2 as published by the Free Software 7** GNU General Public License version 2 as published by the Free Software
8** Foundation and appearing in the file LICENSE.GPL included in the 8** Foundation and appearing in the file LICENSE.GPL included in the
9** packaging of this file. 9** packaging of this file.
10** 10**
11** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE 11** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
12** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. 12** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
13** 13**
14**********************************************************************/ 14**********************************************************************/
15 15
16#ifndef WELLENREITERCONFIGWINDOW_H 16#ifndef WELLENREITERCONFIGWINDOW_H
17#define WELLENREITERCONFIGWINDOW_H 17#define WELLENREITERCONFIGWINDOW_H
18 18
19#include "configbase.h" 19#include "configbase.h"
20#include <qmap.h> 20#include <qmap.h>
21#include <qcombobox.h> 21#include <qcombobox.h>
22#include <qstring.h> 22#include <qstring.h>
23 23
24const int DEVTYPE_SELECT = 0; 24const int DEVTYPE_SELECT = 0;
25const int DEVTYPE_CISCO = 1; 25const int DEVTYPE_CISCO = 1;
26const int DEVTYPE_WLAN_NG = 2; 26const int DEVTYPE_WLAN_NG = 2;
27const int DEVTYPE_HOSTAP = 3; 27const int DEVTYPE_HOSTAP = 3;
28const int DEVTYPE_ORINOCO = 4; 28const int DEVTYPE_ORINOCO = 4;
29const int DEVTYPE_MANUAL = 5; 29const int DEVTYPE_MANUAL = 5;
30const int DEVTYPE_FILE = 6; 30const int DEVTYPE_FILE = 6;
31 31
32class WellenreiterConfigWindow; 32class WellenreiterConfigWindow;
33 33
34class WellenreiterConfigWindow : public WellenreiterConfigBase 34class WellenreiterConfigWindow : public WellenreiterConfigBase
35{ 35{
36 Q_OBJECT 36 Q_OBJECT
37 37
38 public: 38 public:
39 WellenreiterConfigWindow( QWidget * parent = 0, const char * name = "WellenreiterConfigWindow", WFlags f = 0 ); 39 WellenreiterConfigWindow( QWidget * parent = 0, const char * name = "WellenreiterConfigWindow", WFlags f = 0 );
40 int driverType() const; 40 int driverType() const;
41 const QString soundOnNetwork() const { return "";/*netSound->currentText();*/ }; 41 const QString soundOnNetwork() const { return "";/*netSound->currentText();*/ };
42 const QString soundOnBeacon() const { return "";/*beaconSound->currentText();*/ }; 42 const QString soundOnBeacon() const { return "";/*beaconSound->currentText();*/ };
43 static WellenreiterConfigWindow* instance() { return _instance; }; 43 static WellenreiterConfigWindow* instance() { return _instance; };
44 44
45 int hoppingInterval() const; 45 int hoppingInterval() const;
46 bool usePrismHeader() const; 46 bool usePrismHeader() const;
47 bool isChannelChecked( int ) const; 47 bool isChannelChecked( int ) const;
48 48
49 bool useGPS() const;
50 const QString gpsHost() const;
51 int gpsPort() const;
52
49 public slots: 53 public slots:
50 void changedDeviceType(int); 54 void changedDeviceType(int);
51 void getCaptureFileNameClicked(); 55 void getCaptureFileNameClicked();
52 56
53 void channelAllClicked(int); 57 void channelAllClicked(int);
54 58
55 protected: 59 protected:
56 QMap<QString, int> _devicetype; 60 QMap<QString, int> _devicetype;
57 static WellenreiterConfigWindow* _instance; 61 static WellenreiterConfigWindow* _instance;
58 int _guess; 62 int _guess;
59 63
60}; 64};
61 65
62#endif 66#endif
diff --git a/noncore/net/wellenreiter/gui/gps.cpp b/noncore/net/wellenreiter/gui/gps.cpp
index c3bff53..4a24647 100644
--- a/noncore/net/wellenreiter/gui/gps.cpp
+++ b/noncore/net/wellenreiter/gui/gps.cpp
@@ -1,17 +1,65 @@
1/********************************************************************** 1/**********************************************************************
2** Copyright (C) 2003 Michael 'Mickey' Lauer. All rights reserved. 2** Copyright (C) 2003 Michael 'Mickey' Lauer. All rights reserved.
3** 3**
4** This file is part of Opie Environment. 4** This file is part of Opie Environment.
5** 5**
6** This file may be distributed and/or modified under the terms of the 6** This file may be distributed and/or modified under the terms of the
7** GNU General Public License version 2 as published by the Free Software 7** GNU General Public License version 2 as published by the Free Software
8** Foundation and appearing in the file LICENSE.GPL included in the 8** Foundation and appearing in the file LICENSE.GPL included in the
9** packaging of this file. 9** packaging of this file.
10** 10**
11** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE 11** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
12** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. 12** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
13** 13**
14**********************************************************************/ 14**********************************************************************/
15 15
16#include "gps.h" 16#include "gps.h"
17 17
18GPS::GPS( QObject* parent, const char * name )
19 :QObject( parent, name )
20{
21 qDebug( "GPS::GPS()" );
22 _socket = new QSocket( this, "gpsd commsock" );
23}
24
25
26GPS::~GPS()
27{
28 qDebug( "GPS::~GPS()" );
29}
30
31
32bool GPS::open( const QString& host, int port )
33{
34 _socket->connectToHost( host, port );
35}
36
37
38float GPS::latitude() const
39{
40 char buf[256];
41
42 int result = _socket->writeBlock( "p\r\n", 3 );
43 if ( result )
44 {
45 qDebug( "GPS write succeeded" );
46 _socket->waitForMore( 20 );
47 if ( _socket->canReadLine() )
48 {
49
50 int num = _socket->readLine( &buf[0], sizeof buf );
51 if ( num )
52 {
53 qDebug( "GPS got line: %s", &buf );
54 return 0.0;
55 }
56 }
57 }
58 return -1.0;
59}
60
61
62float GPS::longitute() const
63{
64}
65
diff --git a/noncore/net/wellenreiter/gui/gps.h b/noncore/net/wellenreiter/gui/gps.h
index e7c3dce..ad0b6de 100644
--- a/noncore/net/wellenreiter/gui/gps.h
+++ b/noncore/net/wellenreiter/gui/gps.h
@@ -1,19 +1,38 @@
1/********************************************************************** 1/**********************************************************************
2** Copyright (C) 2003 Michael 'Mickey' Lauer. All rights reserved. 2** Copyright (C) 2003 Michael 'Mickey' Lauer. All rights reserved.
3** 3**
4** This file is part of Opie Environment. 4** This file is part of Opie Environment.
5** 5**
6** This file may be distributed and/or modified under the terms of the 6** This file may be distributed and/or modified under the terms of the
7** GNU General Public License version 2 as published by the Free Software 7** GNU General Public License version 2 as published by the Free Software
8** Foundation and appearing in the file LICENSE.GPL included in the 8** Foundation and appearing in the file LICENSE.GPL included in the
9** packaging of this file. 9** packaging of this file.
10** 10**
11** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE 11** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
12** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. 12** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
13** 13**
14**********************************************************************/ 14**********************************************************************/
15 15
16#ifndef GPS_H 16#ifndef GPS_H
17#define GPS_H 17#define GPS_H
18 18
19#include <qobject.h>
20#include <qsocket.h>
21
22class GPS : public QObject
23{
24 Q_OBJECT
25
26 public:
27 GPS( QObject* parent = 0, const char * name = "GPS" );
28 ~GPS();
29
30 bool open( const QString& host = "localhost", int port = 2947 );
31 float latitude() const;
32 float longitute() const;
33
34 private:
35 QSocket* _socket;
36};
37
19#endif // GPS_H 38#endif // GPS_H
diff --git a/noncore/net/wellenreiter/gui/wellenreiter.cpp b/noncore/net/wellenreiter/gui/wellenreiter.cpp
index 96733ff..c03debb 100644
--- a/noncore/net/wellenreiter/gui/wellenreiter.cpp
+++ b/noncore/net/wellenreiter/gui/wellenreiter.cpp
@@ -1,537 +1,563 @@
1/********************************************************************** 1/**********************************************************************
2** Copyright (C) 2002 Michael 'Mickey' Lauer. All rights reserved. 2** Copyright (C) 2002 Michael 'Mickey' Lauer. All rights reserved.
3** 3**
4** This file is part of Opie Environment. 4** This file is part of Opie Environment.
5** 5**
6** This file may be distributed and/or modified under the terms of the 6** This file may be distributed and/or modified under the terms of the
7** GNU General Public License version 2 as published by the Free Software 7** GNU General Public License version 2 as published by the Free Software
8** Foundation and appearing in the file LICENSE.GPL included in the 8** Foundation and appearing in the file LICENSE.GPL included in the
9** packaging of this file. 9** packaging of this file.
10** 10**
11** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE 11** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
12** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. 12** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
13** 13**
14***********************************************************************/ 14***********************************************************************/
15 15
16// Local 16// Local
17 17
18#include "gps.h"
18#include "wellenreiter.h" 19#include "wellenreiter.h"
19#include "scanlist.h" 20#include "scanlist.h"
20#include "logwindow.h" 21#include "logwindow.h"
21#include "hexwindow.h" 22#include "hexwindow.h"
22#include "configwindow.h" 23#include "configwindow.h"
23#include "statwindow.h" 24#include "statwindow.h"
24#include "graphwindow.h" 25#include "graphwindow.h"
25#include "protolistview.h" 26#include "protolistview.h"
26 27
27// Opie 28// Opie
28 29
29#ifdef QWS 30#ifdef QWS
30#include <opie/odevice.h> 31#include <opie/odevice.h>
31#include <qpe/qcopenvelope_qws.h> 32#include <qpe/qcopenvelope_qws.h>
32using namespace Opie; 33using namespace Opie;
33#endif 34#endif
34 35
35#ifdef QWS 36#ifdef QWS
36#include <opie2/oapplication.h> 37#include <opie2/oapplication.h>
37#else 38#else
38#include <qapplication.h> 39#include <qapplication.h>
39#endif 40#endif
40#include <opie2/onetwork.h> 41#include <opie2/onetwork.h>
41#include <opie2/opcap.h> 42#include <opie2/opcap.h>
42 43
43// Qt 44// Qt
44 45
45#include <qcheckbox.h> 46#include <qcheckbox.h>
46#include <qcombobox.h> 47#include <qcombobox.h>
47#include <qdatetime.h> 48#include <qdatetime.h>
48#include <qpushbutton.h> 49#include <qpushbutton.h>
49#include <qlineedit.h> 50#include <qlineedit.h>
50#include <qmessagebox.h> 51#include <qmessagebox.h>
51#include <qobjectlist.h> 52#include <qobjectlist.h>
52#include <qregexp.h> 53#include <qregexp.h>
53#include <qspinbox.h> 54#include <qspinbox.h>
54#include <qtoolbutton.h> 55#include <qtoolbutton.h>
55#include <qmainwindow.h> 56#include <qmainwindow.h>
56 57
57// Standard 58// Standard
58 59
59#include <assert.h> 60#include <assert.h>
60#include <errno.h> 61#include <errno.h>
61#include <unistd.h> 62#include <unistd.h>
62#include <string.h> 63#include <string.h>
63#include <sys/types.h> 64#include <sys/types.h>
64#include <stdlib.h> 65#include <stdlib.h>
65 66
66Wellenreiter::Wellenreiter( QWidget* parent ) 67Wellenreiter::Wellenreiter( QWidget* parent )
67 : WellenreiterBase( parent, 0, 0 ), 68 : WellenreiterBase( parent, 0, 0 ),
68 sniffing( false ), iface( 0 ), configwindow( 0 ) 69 sniffing( false ), iface( 0 ), configwindow( 0 )
69{ 70{
70 71
71 logwindow->log( "(i) Wellenreiter has been started." ); 72 logwindow->log( "(i) Wellenreiter has been started." );
72 73
73 // 74 //
74 // detect operating system 75 // detect operating system
75 // 76 //
76 77
77 #ifdef QWS 78 #ifdef QWS
78 QString sys; 79 QString sys;
79 sys.sprintf( "(i) Running on '%s'.", (const char*) ODevice::inst()->systemString() ); 80 sys.sprintf( "(i) Running on '%s'.", (const char*) ODevice::inst()->systemString() );
80 _system = ODevice::inst()->system(); 81 _system = ODevice::inst()->system();
81 logwindow->log( sys ); 82 logwindow->log( sys );
82 #endif 83 #endif
83 84
84 netview->setColumnWidthMode( 1, QListView::Manual ); 85 netview->setColumnWidthMode( 1, QListView::Manual );
85 connect( netview, SIGNAL( joinNetwork(const QString&,const QString&,int,const QString&) ), 86 connect( netview, SIGNAL( joinNetwork(const QString&,const QString&,int,const QString&) ),
86 this, SLOT( joinNetwork(const QString&,const QString&,int,const QString&) ) ); 87 this, SLOT( joinNetwork(const QString&,const QString&,int,const QString&) ) );
87 pcap = new OPacketCapturer(); 88 pcap = new OPacketCapturer();
89
90 gps = new GPS( this );
88} 91}
89 92
90 93
91Wellenreiter::~Wellenreiter() 94Wellenreiter::~Wellenreiter()
92{ 95{
93 delete pcap; 96 delete pcap;
94} 97}
95 98
96 99
97void Wellenreiter::setConfigWindow( WellenreiterConfigWindow* cw ) 100void Wellenreiter::setConfigWindow( WellenreiterConfigWindow* cw )
98{ 101{
99 configwindow = cw; 102 configwindow = cw;
100} 103}
101 104
102 105
103void Wellenreiter::channelHopped(int c) 106void Wellenreiter::channelHopped(int c)
104{ 107{
105 QString title = "Wellenreiter II -scan- ["; 108 QString title = "Wellenreiter II -scan- [";
106 QString left; 109 QString left;
107 if ( c > 1 ) left.fill( '.', c-1 ); 110 if ( c > 1 ) left.fill( '.', c-1 );
108 title.append( left ); 111 title.append( left );
109 title.append( '|' ); 112 title.append( '|' );
110 if ( c < iface->channels() ) 113 if ( c < iface->channels() )
111 { 114 {
112 QString right; 115 QString right;
113 right.fill( '.', iface->channels()-c ); 116 right.fill( '.', iface->channels()-c );
114 title.append( right ); 117 title.append( right );
115 } 118 }
116 title.append( "]" ); 119 title.append( "]" );
117 //title.append( QString().sprintf( " %02d", c ) ); 120 //title.append( QString().sprintf( " %02d", c ) );
118 assert( parent() ); 121 assert( parent() );
119 ( (QMainWindow*) parent() )->setCaption( title ); 122 ( (QMainWindow*) parent() )->setCaption( title );
120} 123}
121 124
122 125
123void Wellenreiter::handleNotification( OPacket* p ) 126void Wellenreiter::handleNotification( OPacket* p )
124{ 127{
125 QObjectList* l = p->queryList(); 128 QObjectList* l = p->queryList();
126 QObjectListIt it( *l ); 129 QObjectListIt it( *l );
127 QObject* o; 130 QObject* o;
128 131
129 while ( (o = it.current()) != 0 ) 132 while ( (o = it.current()) != 0 )
130 { 133 {
131 QString name = it.current()->name(); 134 QString name = it.current()->name();
132 if ( configwindow->parsePackets->isProtocolChecked( name ) ) 135 if ( configwindow->parsePackets->isProtocolChecked( name ) )
133 { 136 {
134 QString action = configwindow->parsePackets->protocolAction( name ); 137 QString action = configwindow->parsePackets->protocolAction( name );
135 qDebug( "parsePacket-action for '%s' seems to be '%s'", (const char*) name, (const char*) action ); 138 qDebug( "parsePacket-action for '%s' seems to be '%s'", (const char*) name, (const char*) action );
136 doAction( action, name, p ); 139 doAction( action, name, p );
137 } 140 }
138 else 141 else
139 { 142 {
140 qDebug( "protocol '%s' not checked in parsePackets.", (const char*) name ); 143 qDebug( "protocol '%s' not checked in parsePackets.", (const char*) name );
141 } 144 }
142 ++it; 145 ++it;
143 } 146 }
144} 147}
145 148
146 149
147void Wellenreiter::handleBeacon( OPacket* p, OWaveLanManagementPacket* beacon ) 150void Wellenreiter::handleBeacon( OPacket* p, OWaveLanManagementPacket* beacon )
148{ 151{
149 QString type; 152 QString type;
150 if ( beacon->canIBSS() ) 153 if ( beacon->canIBSS() )
151 { 154 {
152 type = "adhoc"; 155 type = "adhoc";
153 } 156 }
154 else if ( beacon->canESS() ) 157 else if ( beacon->canESS() )
155 { 158 {
156 type = "managed"; 159 type = "managed";
157 } 160 }
158 else 161 else
159 { 162 {
160 qWarning( "Wellenreiter::invalid frame [possibly noise] detected!" ); 163 qWarning( "Wellenreiter::invalid frame [possibly noise] detected!" );
161 return; 164 return;
162 } 165 }
163 166
164 OWaveLanManagementSSID* ssid = static_cast<OWaveLanManagementSSID*>( p->child( "802.11 SSID" ) ); 167 OWaveLanManagementSSID* ssid = static_cast<OWaveLanManagementSSID*>( p->child( "802.11 SSID" ) );
165 QString essid = ssid ? ssid->ID() : QString("<unknown>"); 168 QString essid = ssid ? ssid->ID() : QString("<unknown>");
166 OWaveLanManagementDS* ds = static_cast<OWaveLanManagementDS*>( p->child( "802.11 DS" ) ); 169 OWaveLanManagementDS* ds = static_cast<OWaveLanManagementDS*>( p->child( "802.11 DS" ) );
167 int channel = ds ? ds->channel() : -1; 170 int channel = ds ? ds->channel() : -1;
168 171
169 OWaveLanPacket* header = static_cast<OWaveLanPacket*>( p->child( "802.11" ) ); 172 OWaveLanPacket* header = static_cast<OWaveLanPacket*>( p->child( "802.11" ) );
173
174 if ( configwindow->enableGPS->isChecked() )
175 {
176 qDebug( "Wellenreiter::gathering GPS data..." );
177 float lat = gps->latitude();
178 qDebug( "Wellenreiter::GPS data received is ( %f , %f )", lat, 0.0 );
179 }
180
170 netView()->addNewItem( type, essid, header->macAddress2(), beacon->canPrivacy(), channel, 0 ); 181 netView()->addNewItem( type, essid, header->macAddress2(), beacon->canPrivacy(), channel, 0 );
171 182
172 // update graph window 183 // update graph window
173 if ( ds ) 184 if ( ds )
174 { 185 {
175 OPrismHeaderPacket* prism = static_cast<OPrismHeaderPacket*>( p->child( "Prism" ) ); 186 OPrismHeaderPacket* prism = static_cast<OPrismHeaderPacket*>( p->child( "Prism" ) );
176 if ( prism ) 187 if ( prism )
177 graphwindow->traffic( ds->channel(), prism->signalStrength() ); 188 graphwindow->traffic( ds->channel(), prism->signalStrength() );
178 else 189 else
179 graphwindow->traffic( ds->channel(), 95 ); 190 graphwindow->traffic( ds->channel(), 95 );
180 } 191 }
181} 192}
182 193
183 194
184void Wellenreiter::handleData( OPacket* p, OWaveLanDataPacket* data ) 195void Wellenreiter::handleData( OPacket* p, OWaveLanDataPacket* data )
185{ 196{
186 OWaveLanPacket* wlan = (OWaveLanPacket*) p->child( "802.11" ); 197 OWaveLanPacket* wlan = (OWaveLanPacket*) p->child( "802.11" );
187 if ( wlan->fromDS() && !wlan->toDS() ) 198 if ( wlan->fromDS() && !wlan->toDS() )
188 { 199 {
189 netView()->fromDStraffic( wlan->macAddress3(), wlan->macAddress1(), wlan->macAddress2() ); 200 netView()->fromDStraffic( wlan->macAddress3(), wlan->macAddress1(), wlan->macAddress2() );
190 } 201 }
191 else if ( !wlan->fromDS() && wlan->toDS() ) 202 else if ( !wlan->fromDS() && wlan->toDS() )
192 { 203 {
193 netView()->toDStraffic( wlan->macAddress2(), wlan->macAddress3(), wlan->macAddress1() ); 204 netView()->toDStraffic( wlan->macAddress2(), wlan->macAddress3(), wlan->macAddress1() );
194 } 205 }
195 else if ( wlan->fromDS() && wlan->toDS() ) 206 else if ( wlan->fromDS() && wlan->toDS() )
196 { 207 {
197 netView()->WDStraffic( wlan->macAddress4(), wlan->macAddress3(), wlan->macAddress1(), wlan->macAddress2() ); 208 netView()->WDStraffic( wlan->macAddress4(), wlan->macAddress3(), wlan->macAddress1(), wlan->macAddress2() );
198 } 209 }
199 else 210 else
200 { 211 {
201 netView()->IBSStraffic( wlan->macAddress2(), wlan->macAddress1(), wlan->macAddress3() ); 212 netView()->IBSStraffic( wlan->macAddress2(), wlan->macAddress1(), wlan->macAddress3() );
202 } 213 }
203 214
204 OARPPacket* arp = (OARPPacket*) p->child( "ARP" ); 215 OARPPacket* arp = (OARPPacket*) p->child( "ARP" );
205 if ( arp ) 216 if ( arp )
206 { 217 {
207 qDebug( "Received ARP traffic (type '%s'): ", (const char*) arp->type() ); 218 qDebug( "Received ARP traffic (type '%s'): ", (const char*) arp->type() );
208 if ( arp->type() == "REQUEST" ) 219 if ( arp->type() == "REQUEST" )
209 { 220 {
210 netView()->identify( arp->senderMacAddress(), arp->senderIPV4Address().toString() ); 221 netView()->identify( arp->senderMacAddress(), arp->senderIPV4Address().toString() );
211 } 222 }
212 else if ( arp->type() == "REPLY" ) 223 else if ( arp->type() == "REPLY" )
213 { 224 {
214 netView()->identify( arp->senderMacAddress(), arp->senderIPV4Address().toString() ); 225 netView()->identify( arp->senderMacAddress(), arp->senderIPV4Address().toString() );
215 netView()->identify( arp->targetMacAddress(), arp->targetIPV4Address().toString() ); 226 netView()->identify( arp->targetMacAddress(), arp->targetIPV4Address().toString() );
216 } 227 }
217 } 228 }
218 229
219 OIPPacket* ip = (OIPPacket*) p->child( "IP" ); 230 OIPPacket* ip = (OIPPacket*) p->child( "IP" );
220 if ( ip ) 231 if ( ip )
221 { 232 {
222 qDebug( "Received IP packet." ); 233 qDebug( "Received IP packet." );
223 } 234 }
224} 235}
225 236
226 237
227QObject* Wellenreiter::childIfToParse( OPacket* p, const QString& protocol ) 238QObject* Wellenreiter::childIfToParse( OPacket* p, const QString& protocol )
228{ 239{
229 if ( configwindow->parsePackets->isProtocolChecked( protocol ) ) 240 if ( configwindow->parsePackets->isProtocolChecked( protocol ) )
230 if ( configwindow->parsePackets->protocolAction( protocol ) == "Discard!" ) 241 if ( configwindow->parsePackets->protocolAction( protocol ) == "Discard!" )
231 return 0; 242 return 0;
232 243
233 return p->child( protocol ); 244 return p->child( protocol );
234} 245}
235 246
236 247
237bool Wellenreiter::checkDumpPacket( OPacket* p ) 248bool Wellenreiter::checkDumpPacket( OPacket* p )
238{ 249{
239 // go through all child packets and see if one is inside the child hierarchy for p 250 // go through all child packets and see if one is inside the child hierarchy for p
240 // if so, do what the user requested (protocolAction), e.g. pass or discard 251 // if so, do what the user requested (protocolAction), e.g. pass or discard
241 if ( !configwindow->writeCaptureFile->isOn() ) 252 if ( !configwindow->writeCaptureFile->isChecked() )
242 return false; 253 return false;
243 254
244 QObjectList* l = p->queryList(); 255 QObjectList* l = p->queryList();
245 QObjectListIt it( *l ); 256 QObjectListIt it( *l );
246 QObject* o; 257 QObject* o;
247 258
248 while ( (o = it.current()) != 0 ) 259 while ( (o = it.current()) != 0 )
249 { 260 {
250 QString name = it.current()->name(); 261 QString name = it.current()->name();
251 if ( configwindow->capturePackets->isProtocolChecked( name ) ) 262 if ( configwindow->capturePackets->isProtocolChecked( name ) )
252 { 263 {
253 QString action = configwindow->capturePackets->protocolAction( name ); 264 QString action = configwindow->capturePackets->protocolAction( name );
254 qDebug( "capturePackets-action for '%s' seems to be '%s'", (const char*) name, (const char*) action ); 265 qDebug( "capturePackets-action for '%s' seems to be '%s'", (const char*) name, (const char*) action );
255 if ( action == "Discard" ) 266 if ( action == "Discard" )
256 { 267 {
257 logwindow->log( QString().sprintf( "(i) dump-discarding of '%s' packet requested.", (const char*) name ) ); 268 logwindow->log( QString().sprintf( "(i) dump-discarding of '%s' packet requested.", (const char*) name ) );
258 return false; 269 return false;
259 } 270 }
260 } 271 }
261 else 272 else
262 { 273 {
263 qDebug( "protocol '%s' not checked in capturePackets.", (const char*) name ); 274 qDebug( "protocol '%s' not checked in capturePackets.", (const char*) name );
264 } 275 }
265 ++it; 276 ++it;
266 } 277 }
267 return true; 278 return true;
268} 279}
269 280
270 281
271void Wellenreiter::receivePacket( OPacket* p ) 282void Wellenreiter::receivePacket( OPacket* p )
272{ 283{
273 hexWindow()->log( p->dump( 8 ) ); 284 hexWindow()->log( p->dump( 8 ) );
274 285
275 if ( checkDumpPacket( p ) ) 286 if ( checkDumpPacket( p ) )
276 { 287 {
277 pcap->dump( p ); 288 pcap->dump( p );
278 } 289 }
279 290
280 // check if we received a beacon frame 291 // check if we received a beacon frame
281 OWaveLanManagementPacket* beacon = static_cast<OWaveLanManagementPacket*>( childIfToParse( p, "802.11 Management" ) ); 292 OWaveLanManagementPacket* beacon = static_cast<OWaveLanManagementPacket*>( childIfToParse( p, "802.11 Management" ) );
282 if ( beacon && beacon->managementType() == "Beacon" ) 293 if ( beacon && beacon->managementType() == "Beacon" )
283 { 294 {
284 handleBeacon( p, beacon ); 295 handleBeacon( p, beacon );
285 return; 296 return;
286 } 297 }
287 298
288 //TODO: WEP check here 299 //TODO: WEP check here
289 300
290 // check for a data frame 301 // check for a data frame
291 OWaveLanDataPacket* data = static_cast<OWaveLanDataPacket*>( childIfToParse( p, "802.11 Data" ) ); 302 OWaveLanDataPacket* data = static_cast<OWaveLanDataPacket*>( childIfToParse( p, "802.11 Data" ) );
292 if ( data ) 303 if ( data )
293 { 304 {
294 handleData( p, data ); 305 handleData( p, data );
295 } 306 }
296 307
297 handleNotification( p ); 308 handleNotification( p );
298 309
299} 310}
300 311
301 312
302void Wellenreiter::stopClicked() 313void Wellenreiter::stopClicked()
303{ 314{
304 if ( iface ) 315 if ( iface )
305 { 316 {
306 disconnect( SIGNAL( receivedPacket(OPacket*) ), this, SLOT( receivePacket(OPacket*) ) ); 317 disconnect( SIGNAL( receivedPacket(OPacket*) ), this, SLOT( receivePacket(OPacket*) ) );
307 disconnect( SIGNAL( hopped(int) ), this, SLOT( channelHopped(int) ) ); 318 disconnect( SIGNAL( hopped(int) ), this, SLOT( channelHopped(int) ) );
308 iface->setChannelHopping(); // stop hopping channels 319 iface->setChannelHopping(); // stop hopping channels
309 } 320 }
310 else 321 else
311 killTimers(); 322 killTimers();
312 323
313 pcap->close(); 324 pcap->close();
314 sniffing = false; 325 sniffing = false;
315 326
316 if ( iface ) 327 if ( iface )
317 { 328 {
318 // switch off monitor mode 329 // switch off monitor mode
319 iface->setMonitorMode( false ); 330 iface->setMonitorMode( false );
320 // switch off promisc flag 331 // switch off promisc flag
321 iface->setPromiscuousMode( false ); 332 iface->setPromiscuousMode( false );
322 333
323 system( "cardctl reset; sleep 1" ); //FIXME: Use OProcess 334 system( "cardctl reset; sleep 1" ); //FIXME: Use OProcess
324 } 335 }
325 336
326 logwindow->log( "(i) Stopped Scanning." ); 337 logwindow->log( "(i) Stopped Scanning." );
327 assert( parent() ); 338 assert( parent() );
328 ( (QMainWindow*) parent() )->setCaption( "Wellenreiter II" ); 339 ( (QMainWindow*) parent() )->setCaption( "Wellenreiter II" );
329 340
330 // message the user 341 // message the user
331 QMessageBox::information( this, "Wellenreiter II", 342 QMessageBox::information( this, "Wellenreiter II",
332 tr( "Your wireless card\nshould now be usable again." ) ); 343 tr( "Your wireless card\nshould now be usable again." ) );
333 344
334 sniffing = false; 345 sniffing = false;
335 emit( stoppedSniffing() ); 346 emit( stoppedSniffing() );
336 347
337 // print out statistics 348 // print out statistics
338 for( QMap<QString,int>::ConstIterator it = pcap->statistics().begin(); it != pcap->statistics().end(); ++it ) 349 for( QMap<QString,int>::ConstIterator it = pcap->statistics().begin(); it != pcap->statistics().end(); ++it )
339 statwindow->updateCounter( it.key(), it.data() ); 350 statwindow->updateCounter( it.key(), it.data() );
340} 351}
341 352
342 353
343void Wellenreiter::startClicked() 354void Wellenreiter::startClicked()
344{ 355{
345 // get configuration from config window 356 // get configuration from config window
346 357
347 const QString& interface = configwindow->interfaceName->currentText(); 358 const QString& interface = configwindow->interfaceName->currentText();
348 const int cardtype = configwindow->driverType(); 359 const int cardtype = configwindow->driverType();
349 const int interval = configwindow->hoppingInterval(); 360 const int interval = configwindow->hoppingInterval();
350 361
351 if ( ( interface == "" ) || ( cardtype == 0 ) ) 362 if ( ( interface == "" ) || ( cardtype == 0 ) )
352 { 363 {
353 QMessageBox::information( this, "Wellenreiter II", 364 QMessageBox::information( this, "Wellenreiter II",
354 tr( "Your device is not\nproperly configured. Please reconfigure!" ) ); 365 tr( "Your device is not\nproperly configured. Please reconfigure!" ) );
355 return; 366 return;
356 } 367 }
357 368
358 // configure device 369 // configure device
359 ONetwork* net = ONetwork::instance(); 370 ONetwork* net = ONetwork::instance();
360 iface = static_cast<OWirelessNetworkInterface*>(net->interface( interface )); 371
372 // TODO: check if interface is wireless and support sniffing for non-wireless interfaces
373
374 iface = static_cast<OWirelessNetworkInterface*>(net->interface( interface )); // fails if network is not wireless!
361 375
362 // bring device UP 376 // bring device UP
363 iface->setUp( true ); 377 iface->setUp( true );
364 if ( !iface->isUp() ) 378 if ( !iface->isUp() )
365 { 379 {
366 QMessageBox::warning( this, "Wellenreiter II", 380 QMessageBox::warning( this, "Wellenreiter II",
367 tr( "Can't bring interface '%1' up:\n" ).arg( iface->name() ) + strerror( errno ) ); 381 tr( "Can't bring interface '%1' up:\n" ).arg( iface->name() ) + strerror( errno ) );
368 return; 382 return;
369 } 383 }
370 384
371 // set monitor mode 385 // set monitor mode
372 bool usePrism = configwindow->usePrismHeader(); 386 bool usePrism = configwindow->usePrismHeader();
373 387
374 switch ( cardtype ) 388 switch ( cardtype )
375 { 389 {
376 case DEVTYPE_CISCO: iface->setMonitoring( new OCiscoMonitoringInterface( iface, usePrism ) ); break; 390 case DEVTYPE_CISCO: iface->setMonitoring( new OCiscoMonitoringInterface( iface, usePrism ) ); break;
377 case DEVTYPE_WLAN_NG: iface->setMonitoring( new OWlanNGMonitoringInterface( iface, usePrism ) ); break; 391 case DEVTYPE_WLAN_NG: iface->setMonitoring( new OWlanNGMonitoringInterface( iface, usePrism ) ); break;
378 case DEVTYPE_HOSTAP: iface->setMonitoring( new OHostAPMonitoringInterface( iface, usePrism ) ); break; 392 case DEVTYPE_HOSTAP: iface->setMonitoring( new OHostAPMonitoringInterface( iface, usePrism ) ); break;
379 case DEVTYPE_ORINOCO: iface->setMonitoring( new OOrinocoMonitoringInterface( iface, usePrism ) ); break; 393 case DEVTYPE_ORINOCO: iface->setMonitoring( new OOrinocoMonitoringInterface( iface, usePrism ) ); break;
380 case DEVTYPE_MANUAL: QMessageBox::information( this, "Wellenreiter II", tr( "Bring your device into\nmonitor mode now." ) ); break; 394 case DEVTYPE_MANUAL: QMessageBox::information( this, "Wellenreiter II", tr( "Bring your device into\nmonitor mode now." ) ); break;
381 case DEVTYPE_FILE: qDebug( "Wellenreiter: Capturing from file '%s'", (const char*) interface ); break; 395 case DEVTYPE_FILE: qDebug( "Wellenreiter: Capturing from file '%s'", (const char*) interface ); break;
382 default: assert( 0 ); // shouldn't reach this 396 default: assert( 0 ); // shouldn't reach this
383 } 397 }
384 398
385 // switch device into monitor mode 399 // switch device into monitor mode
386 if ( cardtype < DEVTYPE_FILE ) 400 if ( cardtype < DEVTYPE_FILE )
387 { 401 {
388 if ( cardtype != DEVTYPE_MANUAL ) 402 if ( cardtype != DEVTYPE_MANUAL )
389 iface->setMonitorMode( true ); 403 iface->setMonitorMode( true );
390 if ( !iface->monitorMode() ) 404 if ( !iface->monitorMode() )
391 { 405 {
392 QMessageBox::warning( this, "Wellenreiter II", 406 if ( QMessageBox::warning( this, "Wellenreiter II",
393 tr( "Can't set interface '%1'\ninto monitor mode:\n" ).arg( iface->name() ) + strerror( errno ) ); 407 tr( "Can't set interface '%1'\ninto monitor mode:\n" ).arg( iface->name() ) + strerror( errno ) +
394 return; 408 tr( "\nContinue with limited functionality?" ), QMessageBox::Yes, QMessageBox::No ) == QMessageBox::No )
409 return;
395 } 410 }
396 } 411 }
397 412
413 // open GPS device
414 if ( configwindow->enableGPS->isChecked() )
415 {
416 qDebug( "Wellenreiter:GPS enabled @ %s:%d", (const char*) configwindow->gpsdHost->currentText(), configwindow->gpsdPort->value() );
417 gps->open( configwindow->gpsdHost->currentText(), configwindow->gpsdPort->value() );
418 }
419
398 // open pcap and start sniffing 420 // open pcap and start sniffing
399 if ( cardtype != DEVTYPE_FILE ) 421 if ( cardtype != DEVTYPE_FILE )
400 { 422 {
401 pcap->open( interface ); 423 pcap->open( interface );
402 424
403 if ( configwindow->writeCaptureFile->isOn() ) 425 if ( configwindow->writeCaptureFile->isChecked() )
404 { 426 {
405 QString dumpname( configwindow->captureFileName->text() ); 427 QString dumpname( configwindow->captureFileName->text() );
428 if ( dumpname.isEmpty() ) dumpname = "captureFile";
406 dumpname.append( '-' ); 429 dumpname.append( '-' );
407 dumpname.append( QTime::currentTime().toString().replace( QRegExp( ":" ), "-" ) ); 430 dumpname.append( QTime::currentTime().toString().replace( QRegExp( ":" ), "-" ) );
408 dumpname.append( ".wellenreiter" ); 431 dumpname.append( ".wellenreiter" );
409 pcap->openDumpFile( dumpname ); 432 pcap->openDumpFile( dumpname );
410 } 433 }
411 else 434 else
412 { 435 {
413 pcap->open( interface ); 436 pcap->open( interface );
414 } 437 }
415 } 438 }
416 else 439 else
417 { 440 {
418 pcap->open( QFile( interface ) ); 441 pcap->open( QFile( interface ) );
419 } 442 }
420 443
421 if ( !pcap->isOpen() ) 444 if ( !pcap->isOpen() )
422 { 445 {
423 QMessageBox::warning( this, "Wellenreiter II", 446 QMessageBox::warning( this, "Wellenreiter II",
424 tr( "Can't open packet capturer for '%1':\n" ).arg( iface->name() ) + QString(strerror( errno ) )); 447 tr( "Can't open packet capturer for '%1':\n" ).arg( iface->name() ) + QString(strerror( errno ) ));
425 return; 448 return;
426 } 449 }
427 450
428 // set capturer to non-blocking mode 451 // set capturer to non-blocking mode
429 pcap->setBlocking( false ); 452 pcap->setBlocking( false );
430 453
431 // start channel hopper 454 // start channel hopper
432 if ( cardtype != DEVTYPE_FILE ) 455 if ( cardtype != DEVTYPE_FILE )
433 iface->setChannelHopping( 1000 ); //use interval from config window 456 {
457 logwindow->log( QString().sprintf( "(i) Starting channel hopper (d=%d ms)", configwindow->hopInterval->value() ) );
458 iface->setChannelHopping( configwindow->hopInterval->value() ); //use interval from config window
459 }
434 460
435 if ( cardtype != DEVTYPE_FILE ) 461 if ( cardtype != DEVTYPE_FILE )
436 { 462 {
437 // connect socket notifier and start channel hopper 463 // connect socket notifier and start channel hopper
438 connect( pcap, SIGNAL( receivedPacket(OPacket*) ), this, SLOT( receivePacket(OPacket*) ) ); 464 connect( pcap, SIGNAL( receivedPacket(OPacket*) ), this, SLOT( receivePacket(OPacket*) ) );
439 connect( iface->channelHopper(), SIGNAL( hopped(int) ), this, SLOT( channelHopped(int) ) ); 465 connect( iface->channelHopper(), SIGNAL( hopped(int) ), this, SLOT( channelHopped(int) ) );
440 } 466 }
441 else 467 else
442 { 468 {
443 // start timer for reading packets 469 // start timer for reading packets
444 startTimer( 100 ); 470 startTimer( 100 );
445 } 471 }
446 472
447 logwindow->log( "(i) Started Scanning." ); 473 logwindow->log( "(i) Started Scanning." );
448 sniffing = true; 474 sniffing = true;
449 emit( startedSniffing() ); 475 emit( startedSniffing() );
450 if ( cardtype != DEVTYPE_FILE ) channelHopped( 6 ); // set title 476 if ( cardtype != DEVTYPE_FILE ) channelHopped( 6 ); // set title
451 else 477 else
452 { 478 {
453 assert( parent() ); 479 assert( parent() );
454 ( (QMainWindow*) parent() )->setCaption( tr( "Wellenreiter II - replaying capture file..." ) ); 480 ( (QMainWindow*) parent() )->setCaption( tr( "Wellenreiter II - replaying capture file..." ) );
455 } 481 }
456} 482}
457 483
458 484
459void Wellenreiter::timerEvent( QTimerEvent* ) 485void Wellenreiter::timerEvent( QTimerEvent* )
460{ 486{
461 qDebug( "Wellenreiter::timerEvent()" ); 487 qDebug( "Wellenreiter::timerEvent()" );
462 OPacket* p = pcap->next(); 488 OPacket* p = pcap->next();
463 if ( !p ) // no more packets available 489 if ( !p ) // no more packets available
464 { 490 {
465 stopClicked(); 491 stopClicked();
466 } 492 }
467 else 493 else
468 { 494 {
469 receivePacket( p ); 495 receivePacket( p );
470 delete p; 496 delete p;
471 } 497 }
472} 498}
473 499
474 500
475void Wellenreiter::doAction( const QString& action, const QString& protocol, OPacket* p ) 501void Wellenreiter::doAction( const QString& action, const QString& protocol, OPacket* p )
476{ 502{
477 #ifdef QWS 503 #ifdef QWS
478 if ( action == "TouchSound" ) 504 if ( action == "TouchSound" )
479 ODevice::inst()->touchSound(); 505 ODevice::inst()->touchSound();
480 else if ( action == "AlarmSound" ) 506 else if ( action == "AlarmSound" )
481 ODevice::inst()->alarmSound(); 507 ODevice::inst()->alarmSound();
482 else if ( action == "KeySound" ) 508 else if ( action == "KeySound" )
483 ODevice::inst()->keySound(); 509 ODevice::inst()->keySound();
484 else if ( action == "LedOn" ) 510 else if ( action == "LedOn" )
485 ODevice::inst()->setLedState( Led_Mail, Led_On ); 511 ODevice::inst()->setLedState( Led_Mail, Led_On );
486 else if ( action == "LedOff" ) 512 else if ( action == "LedOff" )
487 ODevice::inst()->setLedState( Led_Mail, Led_Off ); 513 ODevice::inst()->setLedState( Led_Mail, Led_Off );
488 else if ( action == "LogMessage" ) 514 else if ( action == "LogMessage" )
489 logwindow->log( QString().sprintf( "Got packet with protocol '%s'", (const char*) protocol ) ); 515 logwindow->log( QString().sprintf( "Got packet with protocol '%s'", (const char*) protocol ) );
490 else if ( action == "MessageBox" ) 516 else if ( action == "MessageBox" )
491 QMessageBox::information( this, "Notification!", 517 QMessageBox::information( this, "Notification!",
492 QString().sprintf( "Got packet with protocol '%s'", (const char*) protocol ) ); 518 QString().sprintf( "Got packet with protocol '%s'", (const char*) protocol ) );
493 #else 519 #else
494 #warning Actions do not work with Qt/X11 yet 520 #warning Actions do not work with Qt/X11 yet
495 #endif 521 #endif
496} 522}
497 523
498void Wellenreiter::joinNetwork(const QString& type, const QString& essid, int channel, const QString& macaddr) 524void Wellenreiter::joinNetwork(const QString& type, const QString& essid, int channel, const QString& macaddr)
499{ 525{
500 #ifdef QWS 526 #ifdef QWS
501 if ( !iface ) 527 if ( !iface )
502 { 528 {
503 QMessageBox::warning( this, tr( "Can't do that!" ), tr( "No wireless\ninterface available." ) ); 529 QMessageBox::warning( this, tr( "Can't do that!" ), tr( "No wireless\ninterface available." ) );
504 return; 530 return;
505 } 531 }
506 532
507 if ( sniffing ) 533 if ( sniffing )
508 { 534 {
509 QMessageBox::warning( this, tr( "Can't do that!" ), tr( "Stop sniffing before\njoining a net." ) ); 535 QMessageBox::warning( this, tr( "Can't do that!" ), tr( "Stop sniffing before\njoining a net." ) );
510 return; 536 return;
511 } 537 }
512 538
513 qDebug( "joinNetwork() with Interface %s: %s, %s, %d, %s", 539 qDebug( "joinNetwork() with Interface %s: %s, %s, %d, %s",
514 (const char*) iface->name(), 540 (const char*) iface->name(),
515 (const char*) type, 541 (const char*) type,
516 (const char*) essid, 542 (const char*) essid,
517 channel, 543 channel,
518 (const char*) macaddr ); 544 (const char*) macaddr );
519 545
520 QCopEnvelope msg( "QPE/Application/networksettings", "wlan(QString,QString,QString)" ); 546 QCopEnvelope msg( "QPE/Application/networksettings", "wlan(QString,QString,QString)" );
521 int count = 3; 547 int count = 3;
522 qDebug("sending %d messages",count); 548 qDebug("sending %d messages",count);
523 msg << QString("count") << QString::number(count); 549 msg << QString("count") << QString::number(count);
524 qDebug("msg >%s< Mode >%s<", iface->name(),type.latin1() ); 550 qDebug("msg >%s< Mode >%s<", iface->name(),type.latin1() );
525 msg << QString(iface->name()) << QString("Mode") << type; 551 msg << QString(iface->name()) << QString("Mode") << type;
526 qDebug("msg >%s< essid >%s<", iface->name(),essid.latin1()); 552 qDebug("msg >%s< essid >%s<", iface->name(),essid.latin1());
527 msg << QString(iface->name()) << QString("ESSID") << essid; 553 msg << QString(iface->name()) << QString("ESSID") << essid;
528 qDebug("msg >%s< channel >%d<", iface->name(),channel); 554 qDebug("msg >%s< channel >%d<", iface->name(),channel);
529 msg << QString(iface->name()) << QString("Channel") << channel; 555 msg << QString(iface->name()) << QString("Channel") << channel;
530// qDebug("msg >%s< mac >%s<", iface->name(),macaddr); 556// qDebug("msg >%s< mac >%s<", iface->name(),macaddr);
531// msg << QString(iface->name()) << QString("MacAddr") << macaddr; 557// msg << QString(iface->name()) << QString("MacAddr") << macaddr;
532 #else 558 #else
533 QMessageBox::warning( this, tr( "Can't do that!" ), tr( "Function only available on Embedded build" ) ); 559 QMessageBox::warning( this, tr( "Can't do that!" ), tr( "Function only available on Embedded build" ) );
534 #endif 560 #endif
535 561
536} 562}
537 563
diff --git a/noncore/net/wellenreiter/gui/wellenreiter.h b/noncore/net/wellenreiter/gui/wellenreiter.h
index e1062df..43f6f99 100644
--- a/noncore/net/wellenreiter/gui/wellenreiter.h
+++ b/noncore/net/wellenreiter/gui/wellenreiter.h
@@ -1,91 +1,93 @@
1/********************************************************************** 1/**********************************************************************
2** Copyright (C) 2002 Michael 'Mickey' Lauer. All rights reserved. 2** Copyright (C) 2002 Michael 'Mickey' Lauer. All rights reserved.
3** 3**
4** This file is part of Opie Environment. 4** This file is part of Opie Environment.
5** 5**
6** This file may be distributed and/or modified under the terms of the 6** This file may be distributed and/or modified under the terms of the
7** GNU General Public License version 2 as published by the Free Software 7** GNU General Public License version 2 as published by the Free Software
8** Foundation and appearing in the file LICENSE.GPL included in the 8** Foundation and appearing in the file LICENSE.GPL included in the
9** packaging of this file. 9** packaging of this file.
10** 10**
11** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE 11** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
12** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. 12** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
13** 13**
14**********************************************************************/ 14**********************************************************************/
15 15
16#ifndef WELLENREITER_H 16#ifndef WELLENREITER_H
17#define WELLENREITER_H 17#define WELLENREITER_H
18 18
19#include "wellenreiterbase.h" 19#include "wellenreiterbase.h"
20 20
21#ifdef QWS 21#ifdef QWS
22#include <opie/odevice.h> 22#include <opie/odevice.h>
23using namespace Opie; 23using namespace Opie;
24#endif 24#endif
25 25
26class QTimerEvent; 26class QTimerEvent;
27class QPixmap; 27class QPixmap;
28class OPacket; 28class OPacket;
29class OWaveLanManagementPacket; 29class OWaveLanManagementPacket;
30class OWaveLanDataPacket; 30class OWaveLanDataPacket;
31class OPacketCapturer; 31class OPacketCapturer;
32class OWirelessNetworkInterface; 32class OWirelessNetworkInterface;
33class WellenreiterConfigWindow; 33class WellenreiterConfigWindow;
34class MLogWindow; 34class MLogWindow;
35class MHexWindow; 35class MHexWindow;
36class GPS;
36 37
37class Wellenreiter : public WellenreiterBase { 38class Wellenreiter : public WellenreiterBase {
38 Q_OBJECT 39 Q_OBJECT
39 40
40 public: 41 public:
41 Wellenreiter( QWidget* parent = 0 ); 42 Wellenreiter( QWidget* parent = 0 );
42 ~Wellenreiter(); 43 ~Wellenreiter();
43 44
44 void setConfigWindow( WellenreiterConfigWindow* cw ); 45 void setConfigWindow( WellenreiterConfigWindow* cw );
45 MScanListView* netView() const { return netview; }; 46 MScanListView* netView() const { return netview; };
46 MLogWindow* logWindow() const { return logwindow; }; 47 MLogWindow* logWindow() const { return logwindow; };
47 MHexWindow* hexWindow() const { return hexwindow; }; 48 MHexWindow* hexWindow() const { return hexwindow; };
48 bool isDaemonRunning() const { return sniffing; }; 49 bool isDaemonRunning() const { return sniffing; };
49 50
50 public: 51 public:
51 bool sniffing; 52 bool sniffing;
52 53
53 protected: 54 protected:
54 virtual void timerEvent( QTimerEvent* ); 55 virtual void timerEvent( QTimerEvent* );
55 56
56 public slots: 57 public slots:
57 void channelHopped(int); 58 void channelHopped(int);
58 void receivePacket(OPacket*); 59 void receivePacket(OPacket*);
59 void startClicked(); 60 void startClicked();
60 void stopClicked(); 61 void stopClicked();
61 62
62 void joinNetwork(const QString&,const QString&,int,const QString&); 63 void joinNetwork(const QString&,const QString&,int,const QString&);
63 64
64 signals: 65 signals:
65 void startedSniffing(); 66 void startedSniffing();
66 void stoppedSniffing(); 67 void stoppedSniffing();
67 68
68 private: 69 private:
69 void handleBeacon( OPacket* p, OWaveLanManagementPacket* beacon ); 70 void handleBeacon( OPacket* p, OWaveLanManagementPacket* beacon );
70 void handleData( OPacket* p, OWaveLanDataPacket* data ); 71 void handleData( OPacket* p, OWaveLanDataPacket* data );
71 void handleNotification( OPacket* p ); 72 void handleNotification( OPacket* p );
72 void doAction( const QString& action, const QString& protocol, OPacket* p ); 73 void doAction( const QString& action, const QString& protocol, OPacket* p );
73 QObject* childIfToParse( OPacket* p, const QString& protocol ); 74 QObject* childIfToParse( OPacket* p, const QString& protocol );
74 bool checkDumpPacket( OPacket* p ); 75 bool checkDumpPacket( OPacket* p );
75 76
76 private: 77 private:
77 #ifdef QWS 78 #ifdef QWS
78 OSystem _system; // Opie Operating System identifier 79 OSystem _system; // Opie Operating System identifier
79 #endif 80 #endif
80 81
81 OWirelessNetworkInterface* iface; 82 OWirelessNetworkInterface* iface;
82 OPacketCapturer* pcap; 83 OPacketCapturer* pcap;
83 WellenreiterConfigWindow* configwindow; 84 WellenreiterConfigWindow* configwindow;
85 GPS* gps;
84 86
85 //void readConfig(); 87 //void readConfig();
86 //void writeConfig(); 88 //void writeConfig();
87}; 89};
88 90
89 91
90 92
91#endif 93#endif