author | mickeyl <mickeyl> | 2004-10-29 10:51:08 (UTC) |
---|---|---|
committer | mickeyl <mickeyl> | 2004-10-29 10:51:08 (UTC) |
commit | 1cde6419bcf60ec1ba23750106b2ec01474416fb (patch) (unidiff) | |
tree | 80eab25b6ef88621aab36c4bbb1789e4b9d48502 | |
parent | 35262b3fbc09b32d4c5b20004f755e0c5651dc1b (diff) | |
download | opie-1cde6419bcf60ec1ba23750106b2ec01474416fb.zip opie-1cde6419bcf60ec1ba23750106b2ec01474416fb.tar.gz opie-1cde6419bcf60ec1ba23750106b2ec01474416fb.tar.bz2 |
improve english
-rw-r--r-- | noncore/net/wellenreiter/gui/wellenreiter.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/noncore/net/wellenreiter/gui/wellenreiter.cpp b/noncore/net/wellenreiter/gui/wellenreiter.cpp index df8e9c3..9fe463a 100644 --- a/noncore/net/wellenreiter/gui/wellenreiter.cpp +++ b/noncore/net/wellenreiter/gui/wellenreiter.cpp | |||
@@ -526,97 +526,97 @@ void Wellenreiter::stopClicked() | |||
526 | } | 526 | } |
527 | 527 | ||
528 | 528 | ||
529 | void Wellenreiter::startClicked() | 529 | void Wellenreiter::startClicked() |
530 | { | 530 | { |
531 | // get configuration from config window | 531 | // get configuration from config window |
532 | 532 | ||
533 | const QString& interface = configwindow->interfaceName->currentText(); | 533 | const QString& interface = configwindow->interfaceName->currentText(); |
534 | const int cardtype = configwindow->driverType(); | 534 | const int cardtype = configwindow->driverType(); |
535 | // const int interval = configwindow->hoppingInterval(); | 535 | // const int interval = configwindow->hoppingInterval(); |
536 | 536 | ||
537 | if ( ( interface == "" ) || ( cardtype == 0 ) ) | 537 | if ( ( interface == "" ) || ( cardtype == 0 ) ) |
538 | { | 538 | { |
539 | QMessageBox::information( this, "Wellenreiter II", | 539 | QMessageBox::information( this, "Wellenreiter II", |
540 | tr( "No device configured.\nPlease reconfigure!" ) ); | 540 | tr( "No device configured.\nPlease reconfigure!" ) ); |
541 | return; | 541 | return; |
542 | } | 542 | } |
543 | 543 | ||
544 | // configure device | 544 | // configure device |
545 | ONetwork* net = ONetwork::instance(); | 545 | ONetwork* net = ONetwork::instance(); |
546 | 546 | ||
547 | // TODO: check if interface is wireless and support sniffing for non-wireless interfaces | 547 | // TODO: check if interface is wireless and support sniffing for non-wireless interfaces |
548 | 548 | ||
549 | if ( cardtype != DEVTYPE_FILE ) | 549 | if ( cardtype != DEVTYPE_FILE ) |
550 | { | 550 | { |
551 | 551 | ||
552 | if ( !net->isPresent( interface ) ) | 552 | if ( !net->isPresent( interface ) ) |
553 | { | 553 | { |
554 | QMessageBox::information( this, "Wellenreiter II", | 554 | QMessageBox::information( this, "Wellenreiter II", |
555 | tr( "The configured device (%1)\nis not available on this system\n. Please reconfigure!" ).arg( interface ) ); | 555 | tr( "The configured device (%1)\nis not available on this system\n. Please reconfigure!" ).arg( interface ) ); |
556 | return; | 556 | return; |
557 | } | 557 | } |
558 | 558 | ||
559 | iface = static_cast<OWirelessNetworkInterface*>(net->interface( interface )); // fails if network is not wireless! | 559 | iface = static_cast<OWirelessNetworkInterface*>(net->interface( interface )); // fails if network is not wireless! |
560 | assert( iface ); | 560 | assert( iface ); |
561 | 561 | ||
562 | // bring device UP | 562 | // bring device UP |
563 | iface->setUp( true ); | 563 | iface->setUp( true ); |
564 | if ( !iface->isUp() ) | 564 | if ( !iface->isUp() ) |
565 | { | 565 | { |
566 | QMessageBox::warning( this, "Wellenreiter II", | 566 | QMessageBox::warning( this, "Wellenreiter II", |
567 | tr( "Can't bring interface '%1' up:\n" ).arg( iface->name() ) + strerror( errno ) ); | 567 | tr( "Can't bring interface '%1' up:\n" ).arg( iface->name() ) + strerror( errno ) ); |
568 | return; | 568 | return; |
569 | } | 569 | } |
570 | 570 | ||
571 | // check if wireless extension version matches | 571 | // check if wireless extension version matches |
572 | if ( ONetwork::wirelessExtensionCompileVersion() != iface->wirelessExtensionDriverVersion() ) | 572 | if ( ONetwork::wirelessExtensionCompileVersion() != iface->wirelessExtensionDriverVersion() ) |
573 | { | 573 | { |
574 | QMessageBox::critical( this, "Wellenreiter II", tr( "<p>The Wireless Extension Versions<br>are not matching!<p>" | 574 | QMessageBox::critical( this, "Wellenreiter II", tr( "<p>The Wireless Extension Versions<br>do not match!<p>" |
575 | " Wellenreiter II : WE V%1<br>Interface driver: WE V%2" ) | 575 | " Wellenreiter II : WE V%1<br>Interface driver: WE V%2" ) |
576 | .arg( QString::number( ONetwork::wirelessExtensionCompileVersion() ) ) | 576 | .arg( QString::number( ONetwork::wirelessExtensionCompileVersion() ) ) |
577 | .arg( QString::number( iface->wirelessExtensionDriverVersion() ) ) ); | 577 | .arg( QString::number( iface->wirelessExtensionDriverVersion() ) ) ); |
578 | return; | 578 | return; |
579 | } | 579 | } |
580 | } | 580 | } |
581 | // set monitor mode | 581 | // set monitor mode |
582 | bool usePrism = configwindow->usePrismHeader(); | 582 | bool usePrism = configwindow->usePrismHeader(); |
583 | 583 | ||
584 | switch ( cardtype ) | 584 | switch ( cardtype ) |
585 | { | 585 | { |
586 | case DEVTYPE_CISCO: iface->setMonitoring( new OCiscoMonitoringInterface( iface, usePrism ) ); break; | 586 | case DEVTYPE_CISCO: iface->setMonitoring( new OCiscoMonitoringInterface( iface, usePrism ) ); break; |
587 | case DEVTYPE_WLAN_NG: iface->setMonitoring( new OWlanNGMonitoringInterface( iface, usePrism ) ); break; | 587 | case DEVTYPE_WLAN_NG: iface->setMonitoring( new OWlanNGMonitoringInterface( iface, usePrism ) ); break; |
588 | case DEVTYPE_HOSTAP: iface->setMonitoring( new OHostAPMonitoringInterface( iface, usePrism ) ); break; | 588 | case DEVTYPE_HOSTAP: iface->setMonitoring( new OHostAPMonitoringInterface( iface, usePrism ) ); break; |
589 | case DEVTYPE_ORINOCO: iface->setMonitoring( new OOrinocoMonitoringInterface( iface, usePrism ) ); break; | 589 | case DEVTYPE_ORINOCO: iface->setMonitoring( new OOrinocoMonitoringInterface( iface, usePrism ) ); break; |
590 | case DEVTYPE_MANUAL: QMessageBox::information( this, "Wellenreiter II", tr( "Bring your device into\nmonitor mode now." ) ); break; | 590 | case DEVTYPE_MANUAL: QMessageBox::information( this, "Wellenreiter II", tr( "Bring your device into\nmonitor mode now." ) ); break; |
591 | case DEVTYPE_FILE: odebug << "Wellenreiter: Capturing from file '" << interface << "'" << oendl; break; | 591 | case DEVTYPE_FILE: odebug << "Wellenreiter: Capturing from file '" << interface << "'" << oendl; break; |
592 | default: assert( 0 ); // shouldn't reach this | 592 | default: assert( 0 ); // shouldn't reach this |
593 | } | 593 | } |
594 | 594 | ||
595 | // switch device into monitor mode | 595 | // switch device into monitor mode |
596 | if ( cardtype < DEVTYPE_FILE ) | 596 | if ( cardtype < DEVTYPE_FILE ) |
597 | { | 597 | { |
598 | if ( cardtype != DEVTYPE_MANUAL ) | 598 | if ( cardtype != DEVTYPE_MANUAL ) |
599 | iface->setMode( "monitor" ); | 599 | iface->setMode( "monitor" ); |
600 | if ( iface->mode() != "monitor" ) | 600 | if ( iface->mode() != "monitor" ) |
601 | { | 601 | { |
602 | if ( QMessageBox::warning( this, "Wellenreiter II", | 602 | if ( QMessageBox::warning( this, "Wellenreiter II", |
603 | tr( "Can't set interface '%1'\ninto monitor mode:\n" ).arg( iface->name() ) + strerror( errno ) + | 603 | tr( "Can't set interface '%1'\ninto monitor mode:\n" ).arg( iface->name() ) + strerror( errno ) + |
604 | tr( "\nContinue with limited functionality?" ), QMessageBox::Yes, QMessageBox::No ) == QMessageBox::No ) | 604 | tr( "\nContinue with limited functionality?" ), QMessageBox::Yes, QMessageBox::No ) == QMessageBox::No ) |
605 | return; | 605 | return; |
606 | } | 606 | } |
607 | } | 607 | } |
608 | 608 | ||
609 | // open GPS device | 609 | // open GPS device |
610 | if ( configwindow->enableGPS->isChecked() ) | 610 | if ( configwindow->enableGPS->isChecked() ) |
611 | { | 611 | { |
612 | odebug << "Wellenreiter:GPS enabled @ " << configwindow->gpsdHost->currentText() << ":" << configwindow->gpsdPort->value() << "" << oendl; | 612 | odebug << "Wellenreiter:GPS enabled @ " << configwindow->gpsdHost->currentText() << ":" << configwindow->gpsdPort->value() << "" << oendl; |
613 | gps->open( configwindow->gpsdHost->currentText(), configwindow->gpsdPort->value() ); | 613 | gps->open( configwindow->gpsdHost->currentText(), configwindow->gpsdPort->value() ); |
614 | } | 614 | } |
615 | 615 | ||
616 | // open pcap and start sniffing | 616 | // open pcap and start sniffing |
617 | 617 | ||
618 | if ( configwindow->writeCaptureFile->isChecked() ) // write to a user specified capture file? | 618 | if ( configwindow->writeCaptureFile->isChecked() ) // write to a user specified capture file? |
619 | { | 619 | { |
620 | dumpname = configwindow->captureFileName->text(); | 620 | dumpname = configwindow->captureFileName->text(); |
621 | if ( dumpname.isEmpty() ) dumpname = "captureFile"; | 621 | if ( dumpname.isEmpty() ) dumpname = "captureFile"; |
622 | dumpname.append( '-' ); | 622 | dumpname.append( '-' ); |