summaryrefslogtreecommitdiff
path: root/noncore/apps/opie-reader/main.cpp
Unidiff
Diffstat (limited to 'noncore/apps/opie-reader/main.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/apps/opie-reader/main.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/noncore/apps/opie-reader/main.cpp b/noncore/apps/opie-reader/main.cpp
index 6d706c4..3e1f5e7 100644
--- a/noncore/apps/opie-reader/main.cpp
+++ b/noncore/apps/opie-reader/main.cpp
@@ -1,33 +1,35 @@
1#include "useqpe.h" 1#include "useqpe.h"
2#ifdef USEQPE 2#ifdef USEQPE
3#include <qpe/qpeapplication.h> 3#include <qpe/qpeapplication.h>
4#else 4#else
5#include <qapplication.h> 5#include <qapplication.h>
6#endif 6#endif
7#include "QTReaderApp.h" 7#include "QTReaderApp.h"
8 8
9#include "signal.h" 9#include "signal.h"
10#include "stdio.h"
11#include "time.h"
10 12
11 13
12#ifdef USEQPE 14#ifdef USEQPE
13QTReaderApp* app = NULL; 15QTReaderApp* app = NULL;
14 16
15void handler(int signum) 17void handler(int signum)
16{ 18{
17 if (app != NULL) 19 if (app != NULL)
18 { 20 {
19 app->suspend(); 21 app->suspend();
20 app->saveprefs(); 22 app->saveprefs();
21 } 23 }
22 signal(signum, handler); 24 signal(signum, handler);
23} 25}
24#endif 26#endif
25 27
26int main( int argc, char ** argv ) 28int main( int argc, char ** argv )
27{ 29{
28 30
29#ifdef USEQPE 31#ifdef USEQPE
30 signal(SIGCONT, handler); 32 signal(SIGCONT, handler);
31 QPEApplication a( argc, argv ); 33 QPEApplication a( argc, argv );
32 QTReaderApp m; 34 QTReaderApp m;
33 a.showMainDocumentWidget( &m ); 35 a.showMainDocumentWidget( &m );