summaryrefslogtreecommitdiff
authortille <tille>2003-06-21 15:36:59 (UTC)
committer tille <tille>2003-06-21 15:36:59 (UTC)
commite1e6c04dfb5d2ac785b4b5b0ed21648eb4e4d03b (patch) (side-by-side diff)
tree1d95c13bf5def759982a73ea5f11637f0715097e
parent5f5accf337a109371296c6a78175734454165406 (diff)
downloadopie-e1e6c04dfb5d2ac785b4b5b0ed21648eb4e4d03b.zip
opie-e1e6c04dfb5d2ac785b4b5b0ed21648eb4e4d03b.tar.gz
opie-e1e6c04dfb5d2ac785b4b5b0ed21648eb4e4d03b.tar.bz2
send message cound to networksettings
it's working now on the Z
Diffstat (more/less context) (show whitespace changes)
-rw-r--r--noncore/net/wellenreiter/gui/wellenreiter.cpp10
1 files changed, 9 insertions, 1 deletions
diff --git a/noncore/net/wellenreiter/gui/wellenreiter.cpp b/noncore/net/wellenreiter/gui/wellenreiter.cpp
index 79773b3..dcf796f 100644
--- a/noncore/net/wellenreiter/gui/wellenreiter.cpp
+++ b/noncore/net/wellenreiter/gui/wellenreiter.cpp
@@ -452,71 +452,79 @@ void Wellenreiter::startClicked()
{
assert( parent() );
( (QMainWindow*) parent() )->setCaption( tr( "Wellenreiter II - replaying capture file..." ) );
}
}
void Wellenreiter::timerEvent( QTimerEvent* )
{
qDebug( "Wellenreiter::timerEvent()" );
OPacket* p = pcap->next();
if ( !p ) // no more packets available
{
stopClicked();
}
else
{
receivePacket( p );
delete p;
}
}
void Wellenreiter::doAction( const QString& action, const QString& protocol, OPacket* p )
{
if ( action == "TouchSound" )
ODevice::inst()->touchSound();
else if ( action == "AlarmSound" )
ODevice::inst()->alarmSound();
else if ( action == "KeySound" )
ODevice::inst()->keySound();
else if ( action == "LedOn" )
ODevice::inst()->setLedState( Led_Mail, Led_On );
else if ( action == "LedOff" )
ODevice::inst()->setLedState( Led_Mail, Led_Off );
else if ( action == "LogMessage" )
logwindow->log( QString().sprintf( "Got packet with protocol '%s'", (const char*) protocol ) );
else if ( action == "MessageBox" )
QMessageBox::information( this, "Notification!",
QString().sprintf( "Got packet with protocol '%s'", (const char*) protocol ) );
}
void Wellenreiter::joinNetwork(const QString& type, const QString& essid, int channel, const QString& macaddr)
{
if ( !iface )
{
QMessageBox::warning( this, tr( "Can't do that!" ), tr( "No wireless\ninterface available." ) );
return;
}
if ( sniffing )
{
QMessageBox::warning( this, tr( "Can't do that!" ), tr( "Stop sniffing before\njoining a net." ) );
return;
}
qDebug( "joinNetwork() with Interface %s: %s, %s, %d, %s",
(const char*) iface->name(),
(const char*) type,
(const char*) essid,
channel,
(const char*) macaddr );
QCopEnvelope msg( "QPE/Application/networksettings", "wlan(QString,QString,QString)" );
+ int count = 3;
+ qDebug("sending %d messages",count);
+ msg << QString("count") << QString::number(count);
+ qDebug("msg >%s< Mode >%s<", iface->name(),type.latin1() );
msg << QString(iface->name()) << QString("Mode") << type;
+ qDebug("msg >%s< essid >%s<", iface->name(),essid.latin1());
msg << QString(iface->name()) << QString("ESSID") << essid;
+ qDebug("msg >%s< channel >%d<", iface->name(),channel);
msg << QString(iface->name()) << QString("Channel") << channel;
- msg << QString(iface->name()) << QString("MacAddr") << macaddr;
+// qDebug("msg >%s< mac >%s<", iface->name(),macaddr);
+// msg << QString(iface->name()) << QString("MacAddr") << macaddr;
+
}