Diffstat (limited to 'noncore/net/wellenreiter/gui/wellenreiter.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | noncore/net/wellenreiter/gui/wellenreiter.cpp | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/noncore/net/wellenreiter/gui/wellenreiter.cpp b/noncore/net/wellenreiter/gui/wellenreiter.cpp index be2a86e..b4b6aa3 100644 --- a/noncore/net/wellenreiter/gui/wellenreiter.cpp +++ b/noncore/net/wellenreiter/gui/wellenreiter.cpp | |||
@@ -32,12 +32,13 @@ using namespace Opie; | |||
32 | 32 | ||
33 | #include <qcheckbox.h> | 33 | #include <qcheckbox.h> |
34 | #include <qcombobox.h> | 34 | #include <qcombobox.h> |
35 | #include <qpushbutton.h> | 35 | #include <qpushbutton.h> |
36 | #include <qlineedit.h> | 36 | #include <qlineedit.h> |
37 | #include <qmessagebox.h> | 37 | #include <qmessagebox.h> |
38 | #include <qregexp.h> | ||
38 | #include <qspinbox.h> | 39 | #include <qspinbox.h> |
39 | #include <qtoolbutton.h> | 40 | #include <qtoolbutton.h> |
40 | #include <qmainwindow.h> | 41 | #include <qmainwindow.h> |
41 | 42 | ||
42 | // Standard | 43 | // Standard |
43 | 44 | ||
@@ -322,13 +323,17 @@ void Wellenreiter::startClicked() | |||
322 | 323 | ||
323 | // open pcap and start sniffing | 324 | // open pcap and start sniffing |
324 | if ( cardtype != DEVTYPE_FILE ) | 325 | if ( cardtype != DEVTYPE_FILE ) |
325 | { | 326 | { |
326 | if ( configwindow->writeCaptureFile->isEnabled() ) | 327 | if ( configwindow->writeCaptureFile->isEnabled() ) |
327 | { | 328 | { |
328 | pcap->open( interface, configwindow->captureFileName->text() ); | 329 | QString dumpname( configwindow->captureFileName->text() ); |
330 | dumpname.append( '-' ); | ||
331 | dumpname.append( QTime::currentTime().toString().replace( QRegExp( ":" ), "-" ) ); | ||
332 | dumpname.append( ".wellenreiter" ); | ||
333 | pcap->open( interface, dumpname ); | ||
329 | } | 334 | } |
330 | else | 335 | else |
331 | { | 336 | { |
332 | pcap->open( interface ); | 337 | pcap->open( interface ); |
333 | } | 338 | } |
334 | } | 339 | } |
@@ -362,12 +367,18 @@ void Wellenreiter::startClicked() | |||
362 | startTimer( 100 ); | 367 | startTimer( 100 ); |
363 | } | 368 | } |
364 | 369 | ||
365 | logwindow->log( "(i) Started Scanning." ); | 370 | logwindow->log( "(i) Started Scanning." ); |
366 | sniffing = true; | 371 | sniffing = true; |
367 | emit( startedSniffing() ); | 372 | emit( startedSniffing() ); |
373 | if ( cardtype != DEVTYPE_FILE ) channelHopped( 6 ); // set title | ||
374 | else | ||
375 | { | ||
376 | assert( parent() ); | ||
377 | ( (QMainWindow*) parent() )->setCaption( "Wellenreiter II - replaying capture file..." ); | ||
378 | } | ||
368 | } | 379 | } |
369 | 380 | ||
370 | 381 | ||
371 | void Wellenreiter::timerEvent( QTimerEvent* ) | 382 | void Wellenreiter::timerEvent( QTimerEvent* ) |
372 | { | 383 | { |
373 | qDebug( "Wellenreiter::timerEvent()" ); | 384 | qDebug( "Wellenreiter::timerEvent()" ); |