summaryrefslogtreecommitdiff
path: root/noncore/settings/networksettings/ppp/pppmodule.cpp
authortille <tille>2003-05-25 14:25:23 (UTC)
committer tille <tille>2003-05-25 14:25:23 (UTC)
commit61c6231cdcde59f8a3ecff31b9fab37f7e9d8852 (patch) (side-by-side diff)
tree4724031209e2263c872ad6160ea61a793f09ed1e /noncore/settings/networksettings/ppp/pppmodule.cpp
parentefa6dfa3428746451dd5a9b5e1ba57806ae96dba (diff)
downloadopie-61c6231cdcde59f8a3ecff31b9fab37f7e9d8852.zip
opie-61c6231cdcde59f8a3ecff31b9fab37f7e9d8852.tar.gz
opie-61c6231cdcde59f8a3ecff31b9fab37f7e9d8852.tar.bz2
save device specific settings
Diffstat (limited to 'noncore/settings/networksettings/ppp/pppmodule.cpp') (more/less context) (show whitespace changes)
-rw-r--r--noncore/settings/networksettings/ppp/pppmodule.cpp18
1 files changed, 10 insertions, 8 deletions
diff --git a/noncore/settings/networksettings/ppp/pppmodule.cpp b/noncore/settings/networksettings/ppp/pppmodule.cpp
index fb2f3e5..3a97535 100644
--- a/noncore/settings/networksettings/ppp/pppmodule.cpp
+++ b/noncore/settings/networksettings/ppp/pppmodule.cpp
@@ -55,9 +55,10 @@ bool PPPModule::isOwner(Interface *i){
* @return QWidget* pointer to this modules configure.
*/
QWidget *PPPModule::configure(Interface *i){
qDebug("return ModemWidget");
- PPPConfigWidget *pppconfig = new PPPConfigWidget( 0, "PPPConfig", false,
+ PPPConfigWidget *pppconfig = new PPPConfigWidget( i, 0, "PPPConfig",
+ false,
Qt::WDestructiveClose );
return pppconfig;
}
@@ -93,20 +94,21 @@ QList<Interface> PPPModule::getInterfaces(){
Interface *PPPModule::addNewInterface(const QString &newInterface){
qDebug("try to add iface %s",newInterface.latin1());
- PPPConfigWidget imp(0, "PPPConfigImp", true);
+ Interface *iface;
+ iface = new Interface();
+ PPPConfigWidget imp(iface, 0, "PPPConfigImp", true);
imp.showMaximized();
if(imp.exec() == QDialog::Accepted ){
- qDebug("ACCEPTED");
- PPPData::data()->save();
- Interface *iface;
- iface = new Interface( 0, PPPData::data()->modemDevice() );
- iface->setHardwareName( PPPData::data()->accname() );
+ iface->setModuleOwner( this );
list.append( iface );
return iface;
+ }else {
+ delete iface;
+ iface = NULL;
}
- return NULL;
+ return iface;
}
/**
* Attempts to remove the interface, doesn't delete i