Diffstat (limited to 'noncore/net/wellenreiter/gui/wellenreiter.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | noncore/net/wellenreiter/gui/wellenreiter.cpp | 18 |
1 files changed, 2 insertions, 16 deletions
diff --git a/noncore/net/wellenreiter/gui/wellenreiter.cpp b/noncore/net/wellenreiter/gui/wellenreiter.cpp index 0105e09..5ec9ee4 100644 --- a/noncore/net/wellenreiter/gui/wellenreiter.cpp +++ b/noncore/net/wellenreiter/gui/wellenreiter.cpp @@ -23,24 +23,25 @@ using namespace Opie; #ifdef QWS #include <opie2/oapplication.h> #else #include <qapplication.h> #endif #include <opie2/onetwork.h> #include <opie2/opcap.h> // Qt #include <qcheckbox.h> #include <qcombobox.h> +#include <qdatetime.h> #include <qpushbutton.h> #include <qlineedit.h> #include <qmessagebox.h> #include <qregexp.h> #include <qspinbox.h> #include <qtoolbutton.h> #include <qmainwindow.h> // Standard #include <assert.h> #include <errno.h> @@ -248,41 +249,26 @@ void Wellenreiter::stopClicked() logwindow->log( "(i) Stopped Scanning." ); assert( parent() ); ( (QMainWindow*) parent() )->setCaption( "Wellenreiter II" ); // message the user QMessageBox::information( this, "Wellenreiter II", "Your wireless card\nshould now be usable again." ); sniffing = false; emit( stoppedSniffing() ); // print out statistics - statwindow->log( "-----------------------------------------" ); - statwindow->log( "- Wellenreiter II Capturing Statistic -" ); - statwindow->log( "-----------------------------------------" ); - statwindow->log( "Packet Type | Receive Count" ); - for( QMap<QString,int>::ConstIterator it = pcap->statistics().begin(); it != pcap->statistics().end(); ++it ) - { - QString left; - left.sprintf( "%s", (const char*) it.key() ); - left = left.leftJustify( 20 ); - left.append( '|' ); - QString right; - right.sprintf( "%d", it.data() ); - right = right.rightJustify( 7 ); - statwindow->log( left + right ); - } - + statwindow->updateCounter( it.key(), it.data() ); } void Wellenreiter::startClicked() { // get configuration from config window const QString& interface = configwindow->interfaceName->currentText(); const int cardtype = configwindow->daemonDeviceType(); const int interval = configwindow->daemonHopInterval(); if ( ( interface == "" ) || ( cardtype == 0 ) ) |