Diffstat (limited to 'noncore/settings/networksettings/ppp/pppconfig.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | noncore/settings/networksettings/ppp/pppconfig.cpp | 29 |
1 files changed, 12 insertions, 17 deletions
diff --git a/noncore/settings/networksettings/ppp/pppconfig.cpp b/noncore/settings/networksettings/ppp/pppconfig.cpp index 4c5f7aa..63f9335 100644 --- a/noncore/settings/networksettings/ppp/pppconfig.cpp +++ b/noncore/settings/networksettings/ppp/pppconfig.cpp @@ -6,5 +6,5 @@ #include "accounts.h" #include "general.h" -#include "interface.h" +#include "interfaceppp.h" #include "modem.h" #include "pppconfig.h" @@ -12,5 +12,5 @@ #include "runtests.h" -PPPConfigWidget::PPPConfigWidget( Interface* iface, QWidget *parent, +PPPConfigWidget::PPPConfigWidget( InterfacePPP* iface, QWidget *parent, const char *name, bool modal, WFlags fl ) @@ -25,14 +25,9 @@ PPPConfigWidget::PPPConfigWidget( Interface* iface, QWidget *parent, interface = iface; - if (!PPPData::data()->setModemDevice( interface->getInterfaceName() )) - PPPData::data()->setModemDevice("/dev/modem"); qDebug("PPPConfigWidget::PPPConfigWidget"); qDebug(" interface->getHardwareName >%s<", interface->getHardwareName().latin1()); - if (!PPPData::data()->setAccount( interface->getHardwareName() )) - PPPData::data()->setAccount( 0 ); - qDebug(" PPPData::data()->accname >%s<",PPPData::data()->accname().latin1()); - qDebug(" PPPData::data()->currentAccountID() >%i<",PPPData::data()->currentAccountID()); - (void)new Modem; + qDebug(" _pppdata->accname >%s<",interface->data()->accname().latin1()); + qDebug(" _pppdata->currentAccountID() >%i<",interface->data()->currentAccountID()); QVBoxLayout *layout = new QVBoxLayout( this ); @@ -42,9 +37,9 @@ PPPConfigWidget::PPPConfigWidget( Interface* iface, QWidget *parent, layout->addWidget( tabWindow ); - accounts = new AccountWidget( tabWindow, "accounts" ); + accounts = new AccountWidget( interface->data(), tabWindow, "accounts" ); tabWindow->addTab( accounts, tr("&Accounts") ); - modem1 = new ModemWidget( tabWindow, "modem1" ); + modem1 = new ModemWidget( interface, tabWindow, "modem1" ); tabWindow->addTab( modem1, tr("&Device") ); - modem2 = new ModemWidget2( tabWindow, "modem2" ); + modem2 = new ModemWidget2( interface, tabWindow, "modem2" ); tabWindow->addTab( modem2, tr("&Modem") ); // graph = new GraphSetup( tabWindow->addPage( tr("&Graph"), tr("Throughput Graph" ) ) ); @@ -62,9 +57,9 @@ void PPPConfigWidget::accept() { qDebug("PPPConfigWidget::accept"); - qDebug(" PPPData::data()->accname >%s<",PPPData::data()->accname().latin1()); + qDebug(" _pppdata->accname >%s<",interface->data()->accname().latin1()); qDebug(" interface->getHardwareName >%s<", interface->getHardwareName().latin1()); - interface->setInterfaceName( PPPData::data()->modemDevice() ); - interface->setHardwareName( PPPData::data()->accname() ); - PPPData::data()->save(); + interface->setInterfaceName( interface->data()->modemDevice() ); + interface->setHardwareName( interface->data()->accname() ); + interface->data()->save(); QDialog::accept(); } @@ -73,5 +68,5 @@ void PPPConfigWidget::accept() void PPPConfigWidget::reject() { - PPPData::data()->cancel(); + interface->data()->cancel(); QDialog::reject(); } |