Diffstat (limited to 'noncore/settings/networksettings/ppp/pppconfig.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | noncore/settings/networksettings/ppp/pppconfig.cpp | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/noncore/settings/networksettings/ppp/pppconfig.cpp b/noncore/settings/networksettings/ppp/pppconfig.cpp index c0f1fef..e2521a6 100644 --- a/noncore/settings/networksettings/ppp/pppconfig.cpp +++ b/noncore/settings/networksettings/ppp/pppconfig.cpp | |||
@@ -5,12 +5,14 @@ | |||
5 | 5 | ||
6 | #include "accounts.h" | 6 | #include "accounts.h" |
7 | #include "general.h" | 7 | #include "general.h" |
8 | #include "interface.h" | ||
9 | #include "modem.h" | ||
8 | #include "pppconfig.h" | 10 | #include "pppconfig.h" |
9 | #include "pppdata.h" | 11 | #include "pppdata.h" |
10 | #include "runtests.h" | 12 | #include "runtests.h" |
11 | #include "modem.h" | ||
12 | 13 | ||
13 | PPPConfigWidget::PPPConfigWidget( QWidget *parent, const char *name, | 14 | PPPConfigWidget::PPPConfigWidget( Interface* iface, QWidget *parent, |
15 | const char *name, | ||
14 | bool modal, WFlags fl ) | 16 | bool modal, WFlags fl ) |
15 | : QDialog(parent, name, modal, fl) | 17 | : QDialog(parent, name, modal, fl) |
16 | { | 18 | { |
@@ -21,8 +23,11 @@ PPPConfigWidget::PPPConfigWidget( QWidget *parent, const char *name, | |||
21 | return; | 23 | return; |
22 | } | 24 | } |
23 | 25 | ||
24 | // setFixedSize(sizeHint()); | 26 | interface = iface; |
25 | 27 | if (!PPPData::data()->setModemDevice( interface->getInterfaceName() )) | |
28 | PPPData::data()->setModemDevice("/dev/modem"); | ||
29 | if (!PPPData::data()->setAccount( interface->getHardwareName() )) | ||
30 | PPPData::data()->setAccount( 0 ); | ||
26 | (void)new Modem; | 31 | (void)new Modem; |
27 | 32 | ||
28 | QVBoxLayout *layout = new QVBoxLayout( this ); | 33 | QVBoxLayout *layout = new QVBoxLayout( this ); |
@@ -50,6 +55,8 @@ PPPConfigWidget::~PPPConfigWidget() | |||
50 | 55 | ||
51 | void PPPConfigWidget::accept() | 56 | void PPPConfigWidget::accept() |
52 | { | 57 | { |
58 | interface->setInterfaceName( PPPData::data()->modemDevice() ); | ||
59 | interface->setHardwareName( PPPData::data()->accname() ); | ||
53 | PPPData::data()->save(); | 60 | PPPData::data()->save(); |
54 | QDialog::accept(); | 61 | QDialog::accept(); |
55 | } | 62 | } |