author | tille <tille> | 2003-06-17 13:05:55 (UTC) |
---|---|---|
committer | tille <tille> | 2003-06-17 13:05:55 (UTC) |
commit | 154d6deef15b9f7f83ea7a25f2079d9fca034910 (patch) (unidiff) | |
tree | 2cb0428922d8d2a4a2adc49b2c62e44cbbdd3b82 | |
parent | e3aff4e49db15c44faf874ee96d666ad56c1d37a (diff) | |
download | opie-154d6deef15b9f7f83ea7a25f2079d9fca034910.zip opie-154d6deef15b9f7f83ea7a25f2079d9fca034910.tar.gz opie-154d6deef15b9f7f83ea7a25f2079d9fca034910.tar.bz2 |
wellenreiter qcop call works now
dns are saved and read in again
3 files changed, 19 insertions, 4 deletions
diff --git a/noncore/settings/networksettings/interfaces/interfacesetupimp.cpp b/noncore/settings/networksettings/interfaces/interfacesetupimp.cpp index 49a47ae..8de30de 100644 --- a/noncore/settings/networksettings/interfaces/interfacesetupimp.cpp +++ b/noncore/settings/networksettings/interfaces/interfacesetupimp.cpp | |||
@@ -179,6 +179,7 @@ void InterfaceSetupImp::setProfile(const QString &profile){ | |||
179 | // IP Information | 179 | // IP Information |
180 | autoStart->setChecked(interfaces->isAuto(interface->getInterfaceName())); | 180 | autoStart->setChecked(interfaces->isAuto(interface->getInterfaceName())); |
181 | QString dns = interfaces->getInterfaceOption("up "DNSSCRIPT" -a", error); | 181 | QString dns = interfaces->getInterfaceOption("up "DNSSCRIPT" -a", error); |
182 | qDebug("dns >%s<",dns.latin1()); | ||
182 | if(dns.contains(" ")){ | 183 | if(dns.contains(" ")){ |
183 | firstDNSLineEdit->setText(dns.mid(0, dns.find(" "))); | 184 | firstDNSLineEdit->setText(dns.mid(0, dns.find(" "))); |
184 | secondDNSLineEdit->setText(dns.mid(dns.find(" ")+1, dns.length())); | 185 | secondDNSLineEdit->setText(dns.mid(dns.find(" ")+1, dns.length())); |
@@ -187,6 +188,8 @@ void InterfaceSetupImp::setProfile(const QString &profile){ | |||
187 | subnetMaskEdit->setText(interfaces->getInterfaceOption("netmask", error)); | 188 | subnetMaskEdit->setText(interfaces->getInterfaceOption("netmask", error)); |
188 | gatewayEdit->setText(interfaces->getInterfaceOption("gateway", error)); | 189 | gatewayEdit->setText(interfaces->getInterfaceOption("gateway", error)); |
189 | 190 | ||
191 | |||
192 | |||
190 | qWarning("InterfaceSetupImp::setProfile(%s)\n", profile.latin1()); | 193 | qWarning("InterfaceSetupImp::setProfile(%s)\n", profile.latin1()); |
191 | qWarning("InterfaceSetupImp::setProfile: iface is %s\n", interfaces->getInterfaceName(error).latin1()); | 194 | qWarning("InterfaceSetupImp::setProfile: iface is %s\n", interfaces->getInterfaceName(error).latin1()); |
192 | 195 | ||
diff --git a/noncore/settings/networksettings/mainwindowimp.cpp b/noncore/settings/networksettings/mainwindowimp.cpp index 8ea241d..2d714ca 100644 --- a/noncore/settings/networksettings/mainwindowimp.cpp +++ b/noncore/settings/networksettings/mainwindowimp.cpp | |||
@@ -640,6 +640,11 @@ void MainWindowImp::receive(const QCString &msg, const QByteArray &arg) | |||
640 | bool found = false; | 640 | bool found = false; |
641 | qDebug("MainWindowImp::receive QCop msg >"+msg+"<"); | 641 | qDebug("MainWindowImp::receive QCop msg >"+msg+"<"); |
642 | 642 | ||
643 | if (msg == "raise") { | ||
644 | raise(); | ||
645 | return; | ||
646 | } | ||
647 | |||
643 | QString dest = msg.left(msg.find("(")); | 648 | QString dest = msg.left(msg.find("(")); |
644 | QCString param = msg.right(msg.length() - msg.find("(") - 1); | 649 | QCString param = msg.right(msg.length() - msg.find("(") - 1); |
645 | param = param.left( param.length() - 1 ); | 650 | param = param.left( param.length() - 1 ); |
diff --git a/noncore/settings/networksettings/wlan/wlanmodule.cpp b/noncore/settings/networksettings/wlan/wlanmodule.cpp index 371b689..7bded85 100644 --- a/noncore/settings/networksettings/wlan/wlanmodule.cpp +++ b/noncore/settings/networksettings/wlan/wlanmodule.cpp | |||
@@ -70,7 +70,7 @@ bool WLANModule::isOwner(Interface *i){ | |||
70 | * @return QWidget* pointer to this modules configure. | 70 | * @return QWidget* pointer to this modules configure. |
71 | */ | 71 | */ |
72 | QWidget *WLANModule::configure(Interface *i){ | 72 | QWidget *WLANModule::configure(Interface *i){ |
73 | WLANImp *wlanconfig = new WLANImp(0, "WlanConfig", i, false, Qt::WDestructiveClose); | 73 | WLANImp *wlanconfig = new WLANImp(0, "WlanConfig", i, true, Qt::WDestructiveClose); |
74 | wlanconfig->setProfile(profile); | 74 | wlanconfig->setProfile(profile); |
75 | return wlanconfig; | 75 | return wlanconfig; |
76 | } | 76 | } |
@@ -132,6 +132,7 @@ void WLANModule::receive(const QCString ¶m, const QByteArray &arg) | |||
132 | QDataStream stream(arg,IO_ReadOnly); | 132 | QDataStream stream(arg,IO_ReadOnly); |
133 | QString interface; | 133 | QString interface; |
134 | QString action; | 134 | QString action; |
135 | QDialog *toShow; | ||
135 | while (! stream.atEnd() ){ | 136 | while (! stream.atEnd() ){ |
136 | stream >> interface; | 137 | stream >> interface; |
137 | stream >> action; | 138 | stream >> action; |
@@ -147,8 +148,8 @@ void WLANModule::receive(const QCString ¶m, const QByteArray &arg) | |||
147 | 148 | ||
148 | if (ifa == 0){ | 149 | if (ifa == 0){ |
149 | qDebug("WLANModule Did not find %s",interface.latin1()); | 150 | qDebug("WLANModule Did not find %s",interface.latin1()); |
150 | qDebug("returning"); | 151 | qDebug("skipping"); |
151 | return; | 152 | count = 0; |
152 | } | 153 | } |
153 | 154 | ||
154 | if (count == 2){ | 155 | if (count == 2){ |
@@ -170,6 +171,7 @@ void WLANModule::receive(const QCString ¶m, const QByteArray &arg) | |||
170 | if (!wlanconfigWiget){ | 171 | if (!wlanconfigWiget){ |
171 | //FIXME: what if it got closed meanwhile? | 172 | //FIXME: what if it got closed meanwhile? |
172 | wlanconfigWiget = (WLANImp*) configure(ifa); | 173 | wlanconfigWiget = (WLANImp*) configure(ifa); |
174 | toShow = (QDialog*) wlanconfigWiget; | ||
173 | } | 175 | } |
174 | wlanconfigWiget->showMaximized(); | 176 | wlanconfigWiget->showMaximized(); |
175 | stream >> value; | 177 | stream >> value; |
@@ -191,8 +193,12 @@ void WLANModule::receive(const QCString ¶m, const QByteArray &arg) | |||
191 | } | 193 | } |
192 | 194 | ||
193 | }else if (action.contains("Channel")){ | 195 | }else if (action.contains("Channel")){ |
196 | bool ok; | ||
197 | int chan = value.toInt( &ok ); | ||
198 | if (ok){ | ||
194 | wlanconfigWiget->specifyChan->setChecked( true ); | 199 | wlanconfigWiget->specifyChan->setChecked( true ); |
195 | wlanconfigWiget->networkChannel->setValue( value.toInt() ); | 200 | wlanconfigWiget->networkChannel->setValue( chan ); |
201 | } | ||
196 | }else if (action.contains("MacAddr")){ | 202 | }else if (action.contains("MacAddr")){ |
197 | wlanconfigWiget->specifyAp->setChecked( true ); | 203 | wlanconfigWiget->specifyAp->setChecked( true ); |
198 | wlanconfigWiget->macEdit->setText( value ); | 204 | wlanconfigWiget->macEdit->setText( value ); |
@@ -200,6 +206,7 @@ void WLANModule::receive(const QCString ¶m, const QByteArray &arg) | |||
200 | qDebug("wlan plugin has no clue"); | 206 | qDebug("wlan plugin has no clue"); |
201 | } | 207 | } |
202 | }// while stream | 208 | }// while stream |
209 | if (toShow) toShow->exec(); | ||
203 | } | 210 | } |
204 | 211 | ||
205 | QWidget *WLANModule::getInfo( Interface *i) | 212 | QWidget *WLANModule::getInfo( Interface *i) |