Diffstat (limited to 'noncore/settings/networksettings/mainwindowimp.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/settings/networksettings/mainwindowimp.cpp | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/noncore/settings/networksettings/mainwindowimp.cpp b/noncore/settings/networksettings/mainwindowimp.cpp index d6b708b..581b7e3 100644 --- a/noncore/settings/networksettings/mainwindowimp.cpp +++ b/noncore/settings/networksettings/mainwindowimp.cpp | |||
@@ -13,14 +13,14 @@ | |||
13 | #include <qlabel.h> | 13 | #include <qlabel.h> |
14 | 14 | ||
15 | #include <qmessagebox.h> | 15 | #include <qmessagebox.h> |
16 | 16 | ||
17 | #ifdef QTE_VERSION | 17 | #ifdef QWS |
18 | #include <qpe/config.h> | 18 | #include <qpe/config.h> |
19 | #include <qpe/qlibrary.h> | 19 | #include <qpe/qlibrary.h> |
20 | #include <qpe/resource.h> | 20 | #include <qpe/resource.h> |
21 | #include <qpe/qpeapplication.h> | 21 | #include <qpe/qpeapplication.h> |
22 | #define QLibrary | 22 | // #define QLibrary Library |
23 | #else | 23 | #else |
24 | #include <klibloader.h> | 24 | #include <klibloader.h> |
25 | #define QLibrary KLibrary | 25 | #define QLibrary KLibrary |
26 | #include <kconfig.h> | 26 | #include <kconfig.h> |
@@ -58,10 +58,10 @@ MainWindowImp::MainWindowImp(QWidget *parent, const char *name) : MainWindow(par | |||
58 | 58 | ||
59 | connect(newProfile, SIGNAL(textChanged(const QString&)), this, SLOT(newProfileChanged(const QString&))); | 59 | connect(newProfile, SIGNAL(textChanged(const QString&)), this, SLOT(newProfileChanged(const QString&))); |
60 | // Load connections. | 60 | // Load connections. |
61 | // /usr/local/kde/lib/libinterfaces.la | 61 | // /usr/local/kde/lib/libinterfaces.la |
62 | #ifdef QTE_VERSION | 62 | #ifdef QWS |
63 | loadModules(QPEApplication::kdeDir() + "/plugins/networksettings"); | 63 | loadModules(QPEApplication::qpeDir() + "/plugins/networksettings"); |
64 | #else | 64 | #else |
65 | loader = KLibLoader::self(); | 65 | loader = KLibLoader::self(); |
66 | loadModules(QString("/usr/")+KStandardDirs::kde_default("lib")); | 66 | loadModules(QString("/usr/")+KStandardDirs::kde_default("lib")); |
67 | #endif | 67 | #endif |
@@ -129,9 +129,9 @@ MainWindowImp::~MainWindowImp(){ | |||
129 | if(iIt.key()->getModuleOwner() == NULL) | 129 | if(iIt.key()->getModuleOwner() == NULL) |
130 | delete iIt.key(); | 130 | delete iIt.key(); |
131 | } | 131 | } |
132 | 132 | ||
133 | #ifdef QTE_VERSION | 133 | #ifdef QWS |
134 | // Delete Modules and Libraries | 134 | // Delete Modules and Libraries |
135 | QMap<Module*, QLibrary*>::Iterator it; | 135 | QMap<Module*, QLibrary*>::Iterator it; |
136 | for( it = libraries.begin(); it != libraries.end(); ++it ){ | 136 | for( it = libraries.begin(); it != libraries.end(); ++it ){ |
137 | delete it.key(); | 137 | delete it.key(); |
@@ -245,9 +245,9 @@ void MainWindowImp::loadModules(const QString &path){ | |||
245 | Module* MainWindowImp::loadPlugin(const QString &pluginFileName, const QString &resolveString){ | 245 | Module* MainWindowImp::loadPlugin(const QString &pluginFileName, const QString &resolveString){ |
246 | #ifdef DEBUG | 246 | #ifdef DEBUG |
247 | qDebug("MainWindowImp::loadPlugin: %s", pluginFileName.latin1()); | 247 | qDebug("MainWindowImp::loadPlugin: %s", pluginFileName.latin1()); |
248 | #endif | 248 | #endif |
249 | #ifdef QTE_VERSION | 249 | #ifdef QWS |
250 | QLibrary *lib = new QLibrary(pluginFileName); | 250 | QLibrary *lib = new QLibrary(pluginFileName); |
251 | void *functionPointer = lib->resolve(resolveString); | 251 | void *functionPointer = lib->resolve(resolveString); |
252 | if( !functionPointer ){ | 252 | if( !functionPointer ){ |
253 | #ifdef DEBUG | 253 | #ifdef DEBUG |
@@ -381,9 +381,9 @@ void MainWindowImp::configureClicked(){ | |||
381 | return; | 381 | return; |
382 | } | 382 | } |
383 | } | 383 | } |
384 | 384 | ||
385 | InterfaceSetupImpDialog *configure = new InterfaceSetupImpDialog(this, "InterfaceSetupImp", i, true, Qt::WShowModal | Qt::WDestructiveClose | Qt::WType_Dialog); | 385 | InterfaceSetupImpDialog *configure = new InterfaceSetupImpDialog(this, "InterfaceSetupImp", i, true, Qt::WType_Modal | Qt::WDestructiveClose | Qt::WStyle_Dialog); |
386 | QString currentProfileText = currentProfileLabel->text(); | 386 | QString currentProfileText = currentProfileLabel->text(); |
387 | if(currentProfileText.upper() == "ALL"); | 387 | if(currentProfileText.upper() == "ALL"); |
388 | currentProfileText = ""; | 388 | currentProfileText = ""; |
389 | configure->setProfile(currentProfileText); | 389 | configure->setProfile(currentProfileText); |
@@ -417,9 +417,9 @@ void MainWindowImp::informationClicked(){ | |||
417 | #endif | 417 | #endif |
418 | return; | 418 | return; |
419 | } | 419 | } |
420 | } | 420 | } |
421 | InterfaceInformationImp *information = new InterfaceInformationImp(this, "InterfaceSetupImp", i, Qt::WShowModal | Qt::WDestructiveClose | Qt::WType_Dialog); | 421 | InterfaceInformationImp *information = new InterfaceInformationImp(this, "InterfaceSetupImp", i, Qt::WType_Modal | Qt::WDestructiveClose | Qt::WStyle_Dialog); |
422 | information->showMaximized(); | 422 | information->showMaximized(); |
423 | } | 423 | } |
424 | 424 | ||
425 | /** | 425 | /** |
@@ -449,9 +449,9 @@ void MainWindowImp::updateInterface(Interface *i){ | |||
449 | else | 449 | else |
450 | item = items[i]; | 450 | item = items[i]; |
451 | 451 | ||
452 | // Update the icons and information | 452 | // Update the icons and information |
453 | #ifdef QTE_VERSION | 453 | #ifdef QWS |
454 | item->setPixmap(0, (Resource::loadPixmap(i->getStatus() ? "up": "down"))); | 454 | item->setPixmap(0, (Resource::loadPixmap(i->getStatus() ? "up": "down"))); |
455 | #else | 455 | #else |
456 | item->setPixmap(0, (SmallIcon(i->getStatus() ? "up": "down"))); | 456 | item->setPixmap(0, (SmallIcon(i->getStatus() ? "up": "down"))); |
457 | #endif | 457 | #endif |
@@ -471,9 +471,9 @@ void MainWindowImp::updateInterface(Interface *i){ | |||
471 | // Actually try to use the Module | 471 | // Actually try to use the Module |
472 | if(i->getModuleOwner() != NULL) | 472 | if(i->getModuleOwner() != NULL) |
473 | typeName = i->getModuleOwner()->getPixmapName(i); | 473 | typeName = i->getModuleOwner()->getPixmapName(i); |
474 | 474 | ||
475 | #ifdef QTE_VERSION | 475 | #ifdef QWS |
476 | item->setPixmap(1, (Resource::loadPixmap(QString("networksettings/") + typeName))); | 476 | item->setPixmap(1, (Resource::loadPixmap(QString("networksettings/") + typeName))); |
477 | #else | 477 | #else |
478 | item->setPixmap(1, (SmallIcon(typeName))); | 478 | item->setPixmap(1, (SmallIcon(typeName))); |
479 | #endif | 479 | #endif |