-rw-r--r-- | noncore/settings/aqpkg/main.cpp | 28 |
1 files changed, 16 insertions, 12 deletions
diff --git a/noncore/settings/aqpkg/main.cpp b/noncore/settings/aqpkg/main.cpp index e943e49..1f8cf42 100644 --- a/noncore/settings/aqpkg/main.cpp +++ b/noncore/settings/aqpkg/main.cpp | |||
@@ -15,8 +15,12 @@ | |||
15 | * * | 15 | * * |
16 | ***************************************************************************/ | 16 | ***************************************************************************/ |
17 | 17 | ||
18 | #include <iostream> | ||
19 | using namespace std; | ||
20 | |||
18 | #ifdef QWS | 21 | #ifdef QWS |
19 | #include <qpe/qpeapplication.h> | 22 | #include <qpe/qpeapplication.h> |
23 | #include <qpe/qcopenvelope_qws.h> | ||
20 | #else | 24 | #else |
21 | #include <qapplication.h> | 25 | #include <qapplication.h> |
22 | #endif | 26 | #endif |
@@ -29,32 +33,32 @@ | |||
29 | #include "global.h" | 33 | #include "global.h" |
30 | 34 | ||
31 | 35 | ||
32 | /* | ||
33 | int main2(int argc, char *argv[]) | ||
34 | { | ||
35 | Server local( "local", "", "status" ); | ||
36 | local.readPackageFile(); | ||
37 | |||
38 | Server s( "opiecvs", "aaa" ); | ||
39 | s.readPackageFile( &local ); | ||
40 | |||
41 | } | ||
42 | */ | ||
43 | |||
44 | int main(int argc, char *argv[]) | 36 | int main(int argc, char *argv[]) |
45 | { | 37 | { |
38 | cout << "Root dir = " << ROOT << endl; | ||
46 | #ifdef QWS | 39 | #ifdef QWS |
47 | QPEApplication a( argc, argv ); | 40 | QPEApplication a( argc, argv ); |
48 | #else | 41 | #else |
49 | QApplication a( argc, argv ); | 42 | QApplication a( argc, argv ); |
50 | #endif | 43 | #endif |
51 | 44 | ||
45 | #ifdef QWS | ||
46 | // Disable suspend mode | ||
47 | cout << "Disabling suspend mode" << endl; | ||
48 | QCopEnvelope( "QPE/System", "setScreenSaverMode(int)" ) << QPEApplication::DisableSuspend; | ||
49 | #endif | ||
50 | |||
52 | MainWindow *win = new MainWindow(); | 51 | MainWindow *win = new MainWindow(); |
53 | a.setMainWidget(win); | 52 | a.setMainWidget(win); |
54 | win->show(); | 53 | win->show(); |
55 | 54 | ||
56 | a.exec(); | 55 | a.exec(); |
57 | 56 | ||
57 | #ifdef QWS | ||
58 | // Reenable suspend mode | ||
59 | cout << "Enabling suspend mode" << endl; | ||
60 | QCopEnvelope( "QPE/System", "setScreenSaverMode(int)" ) << QPEApplication::Enable; | ||
61 | #endif | ||
58 | #ifdef _DEBUG | 62 | #ifdef _DEBUG |
59 | DumpUnfreed(); | 63 | DumpUnfreed(); |
60 | #endif | 64 | #endif |