-rw-r--r-- | kmicromail/main.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/kmicromail/main.cpp b/kmicromail/main.cpp index 1789da0..fe4bc76 100644 --- a/kmicromail/main.cpp +++ b/kmicromail/main.cpp | |||
@@ -22,39 +22,41 @@ | |||
22 | #include <libkdepim/kpimglobalprefs.h> | 22 | #include <libkdepim/kpimglobalprefs.h> |
23 | void dumpMissing(); | 23 | void dumpMissing(); |
24 | //using namespace Opie::Core; | 24 | //using namespace Opie::Core; |
25 | int main( int argc, char **argv ) { | 25 | int main( int argc, char **argv ) { |
26 | 26 | ||
27 | #ifndef DESKTOP_VERSION | 27 | #ifndef DESKTOP_VERSION |
28 | QPEApplication a( argc, argv ); | 28 | QPEApplication a( argc, argv ); |
29 | a.setKeepRunning (); | 29 | a.setKeepRunning (); |
30 | #else | 30 | #else |
31 | QApplication a( argc, argv ); | 31 | QApplication a( argc, argv ); |
32 | QApplication::setStyle( new QPlatinumStyle ()); | 32 | QApplication::setStyle( new QPlatinumStyle ()); |
33 | #endif | 33 | #endif |
34 | a.setFont( KOPrefs::instance()->mAppFont ); | 34 | //a.setFont( KOPrefs::instance()->mAppFont ); |
35 | KGlobal::setAppName( "kopiemail" ); | 35 | KGlobal::setAppName( "kopiemail" ); |
36 | QString fileName ; | 36 | QString fileName ; |
37 | #ifndef DESKTOP_VERSION | 37 | #ifndef DESKTOP_VERSION |
38 | fileName = getenv("QPEDIR"); | 38 | fileName = getenv("QPEDIR"); |
39 | if ( QApplication::desktop()->width() > 320 ) | 39 | if ( QApplication::desktop()->width() > 320 ) |
40 | KGlobal::iconLoader()->setIconPath( fileName +"/pics/kdepim/kopiemail/icons22/"); | 40 | KGlobal::iconLoader()->setIconPath( fileName +"/pics/kdepim/kopiemail/icons22/"); |
41 | else | 41 | else |
42 | KGlobal::iconLoader()->setIconPath( fileName +"/pics/kdepim/kopiemail/"); | 42 | KGlobal::iconLoader()->setIconPath( fileName +"/pics/kdepim/kopiemail/"); |
43 | #else | 43 | #else |
44 | fileName = qApp->applicationDirPath () + "/kdepim/kopiemail/icons22/"; | 44 | fileName = qApp->applicationDirPath () + "/kdepim/kopiemail/icons22/"; |
45 | KGlobal::iconLoader()->setIconPath(QDir::convertSeparators(fileName)); | 45 | KGlobal::iconLoader()->setIconPath(QDir::convertSeparators(fileName)); |
46 | #endif | 46 | #endif |
47 | KStandardDirs::setAppDir( QDir::convertSeparators(locateLocal("data", "kopiemail"))); | 47 | KStandardDirs::setAppDir( QDir::convertSeparators(locateLocal("data", "kopiemail"))); |
48 | KPimGlobalPrefs::instance()->setGlobalConfig(); | 48 | KPimGlobalPrefs::instance()->setGlobalConfig(); |
49 | QApplication::setFont( KPimGlobalPrefs::instance()->mApplicationFont ); | ||
50 | QApplication::setFont( KOPrefs::instance()->mAppFont ); | ||
49 | OpieMail mw; | 51 | OpieMail mw; |
50 | #ifndef DESKTOP_VERSION | 52 | #ifndef DESKTOP_VERSION |
51 | //qDebug("CONNECT "); | 53 | //qDebug("CONNECT "); |
52 | QObject::connect( &a, SIGNAL (appMessage ( const QCString &, const QByteArray & )),&mw, SLOT(message( const QCString&, const QByteArray& ))); | 54 | QObject::connect( &a, SIGNAL (appMessage ( const QCString &, const QByteArray & )),&mw, SLOT(message( const QCString&, const QByteArray& ))); |
53 | // QObject::connect(&a, SIGNAL (appMessage ( const QCString &, const QByteArray & )), ExternalAppHandler::instance(), SLOT (appMessage ( const QCString &, const QByteArray & ))); | 55 | // QObject::connect(&a, SIGNAL (appMessage ( const QCString &, const QByteArray & )), ExternalAppHandler::instance(), SLOT (appMessage ( const QCString &, const QByteArray & ))); |
54 | a.showMainWidget(&mw ); | 56 | a.showMainWidget(&mw ); |
55 | #else | 57 | #else |
56 | a.setMainWidget(&mw ); | 58 | a.setMainWidget(&mw ); |
57 | mw.show(); | 59 | mw.show(); |
58 | //m.resize( 800, 600 ); | 60 | //m.resize( 800, 600 ); |
59 | QObject::connect(&a, SIGNAL(lastWindowClosed()), &a, SLOT(quit())); | 61 | QObject::connect(&a, SIGNAL(lastWindowClosed()), &a, SLOT(quit())); |
60 | #endif | 62 | #endif |