-rw-r--r-- | noncore/settings/networksettings/ppp/interfaceppp.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/noncore/settings/networksettings/ppp/interfaceppp.cpp b/noncore/settings/networksettings/ppp/interfaceppp.cpp index 85ddbee..9ec30bc 100644 --- a/noncore/settings/networksettings/ppp/interfaceppp.cpp +++ b/noncore/settings/networksettings/ppp/interfaceppp.cpp | |||
@@ -9,64 +9,65 @@ | |||
9 | 9 | ||
10 | InterfacePPP::InterfacePPP(QObject *parent, const char *name, bool status) | 10 | InterfacePPP::InterfacePPP(QObject *parent, const char *name, bool status) |
11 | : Interface(parent, name, status), | 11 | : Interface(parent, name, status), |
12 | _modemPtr(0), | 12 | _modemPtr(0), |
13 | _dataPtr(0) | 13 | _dataPtr(0) |
14 | { | 14 | { |
15 | qDebug("InterfacePPP::InterfacePPP("); | 15 | qDebug("InterfacePPP::InterfacePPP("); |
16 | } | 16 | } |
17 | 17 | ||
18 | PPPData* InterfacePPP::data() | 18 | PPPData* InterfacePPP::data() |
19 | { | 19 | { |
20 | if (!_dataPtr){ | 20 | if (!_dataPtr){ |
21 | qDebug("creating new Data obj"); | 21 | qDebug("creating new Data obj"); |
22 | _dataPtr = new PPPData(); | 22 | _dataPtr = new PPPData(); |
23 | _dataPtr->setModemDevice( getInterfaceName() ); | 23 | _dataPtr->setModemDevice( getInterfaceName() ); |
24 | _dataPtr->setAccount( getHardwareName() ); | 24 | _dataPtr->setAccount( getHardwareName() ); |
25 | } | 25 | } |
26 | return _dataPtr; | 26 | return _dataPtr; |
27 | } | 27 | } |
28 | 28 | ||
29 | Modem* InterfacePPP::modem() | 29 | Modem* InterfacePPP::modem() |
30 | { | 30 | { |
31 | if (!_modemPtr){ | 31 | if (!_modemPtr){ |
32 | qDebug("creating new modem obj"); | 32 | qDebug("creating new modem obj"); |
33 | _modemPtr = new Modem( data() ); | 33 | _modemPtr = new Modem( data() ); |
34 | } | 34 | } |
35 | return _modemPtr; | 35 | return _modemPtr; |
36 | } | 36 | } |
37 | 37 | ||
38 | bool InterfacePPP::refresh() | 38 | bool InterfacePPP::refresh() |
39 | { | 39 | { |
40 | qDebug("InterfacePPP::refresh()"); | 40 | qDebug("InterfacePPP::refresh()"); |
41 | updateInterface(this); | ||
41 | QMessageBox::information(0,"Not Implemented","This feature is not yet implemneted... ;-("); | 42 | QMessageBox::information(0,"Not Implemented","This feature is not yet implemneted... ;-("); |
42 | return false; | 43 | return false; |
43 | } | 44 | } |
44 | 45 | ||
45 | void InterfacePPP::start() | 46 | void InterfacePPP::start() |
46 | { | 47 | { |
47 | qDebug("InterfacePPP::start"); | 48 | qDebug("InterfacePPP::start"); |
48 | // should work... | 49 | // should work... |
49 | // if (data()->password().isEmpty() ){ | 50 | // if (data()->password().isEmpty() ){ |
50 | // //FIXME: ask for password | 51 | // //FIXME: ask for password |
51 | // qDebug("using dummy password"); | 52 | // qDebug("using dummy password"); |
52 | // QMessageBox::critical( 0, "no password", "you should be prompted for a password, but you are not! ;-)"); | 53 | // QMessageBox::critical( 0, "no password", "you should be prompted for a password, but you are not! ;-)"); |
53 | // } | 54 | // } |
54 | 55 | ||
55 | 56 | ||
56 | QFileInfo info(pppdPath()); | 57 | QFileInfo info(pppdPath()); |
57 | 58 | ||
58 | if(!info.exists()){ | 59 | if(!info.exists()){ |
59 | QMessageBox::warning(0, tr("Error"), | 60 | QMessageBox::warning(0, tr("Error"), |
60 | i18n("<qt>Cannot find the PPP daemon!<br>" | 61 | i18n("<qt>Cannot find the PPP daemon!<br>" |
61 | "Make sure that pppd is installed and " | 62 | "Make sure that pppd is installed and " |
62 | "that you have entered the correct path.</qt>")); | 63 | "that you have entered the correct path.</qt>")); |
63 | return; | 64 | return; |
64 | } | 65 | } |
65 | //#if 0 | 66 | //#if 0 |
66 | if(!info.isExecutable()){ | 67 | if(!info.isExecutable()){ |
67 | 68 | ||
68 | QString string; | 69 | QString string; |
69 | string = i18n( "<qt>Cannot execute:<br> %1<br>" | 70 | string = i18n( "<qt>Cannot execute:<br> %1<br>" |
70 | "Please make sure that you have given " | 71 | "Please make sure that you have given " |
71 | "setuid permission and that " | 72 | "setuid permission and that " |
72 | "pppd is executable.<br>").arg(pppdPath()); | 73 | "pppd is executable.<br>").arg(pppdPath()); |