summaryrefslogtreecommitdiffabout
path: root/korganizer/main.cpp
authorzautrix <zautrix>2004-07-03 16:49:55 (UTC)
committer zautrix <zautrix>2004-07-03 16:49:55 (UTC)
commit1da48d95d970233f0d1ea9a7fba5c98cfcf24798 (patch) (side-by-side diff)
treeae690b33cbe50291a610842e24de33f9d766f2f2 /korganizer/main.cpp
parente3b89230f065c48c84b48c88edb6eb088374c487 (diff)
downloadkdepimpi-1da48d95d970233f0d1ea9a7fba5c98cfcf24798.zip
kdepimpi-1da48d95d970233f0d1ea9a7fba5c98cfcf24798.tar.gz
kdepimpi-1da48d95d970233f0d1ea9a7fba5c98cfcf24798.tar.bz2
Alarm Bugfix. Added connection to KM. Cleaned up main.
Diffstat (limited to 'korganizer/main.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--korganizer/main.cpp32
1 files changed, 5 insertions, 27 deletions
diff --git a/korganizer/main.cpp b/korganizer/main.cpp
index a357988..69ef294 100644
--- a/korganizer/main.cpp
+++ b/korganizer/main.cpp
@@ -53,38 +53,16 @@ int main( int argc, char **argv )
}
if ( ! exitHelp ) {
KGlobal::setAppName( "korganizer" );
-
-
- QString fileName ;
+ QString fileName ;
#ifndef DESKTOP_VERSION
- QString appdir = QDir::homeDirPath() + "/kdepim/apps/" + KGlobal::getAppName();
- KStandardDirs::setAppDir( appdir );
-
fileName = getenv("QPEDIR");
KGlobal::iconLoader()->setIconPath( fileName +"/pics/kdepim/korganizer/");
#else
-
-#ifndef _WIN32_
- fileName = qApp->applicationDirPath () + "/kdepim/korganizer/";
-#else
- fileName = qApp->applicationDirPath () + "\\kdepim\\korganizer\\";
-#endif
-
- KGlobal::iconLoader()->setIconPath(fileName);
-
- QString appdir = QDir::homeDirPath();
- //appdir = "C:\\";
- if ( appdir.right(1) == "\\" || appdir.right(1) == "/" )
- appdir += "korganizer";
- else
- appdir += "/korganizer";
- KStandardDirs::setAppDir( QDir::convertSeparators( appdir ));
- // qDebug(" %s ",KStandardDirs::appDir().latin1() );
+ fileName = qApp->applicationDirPath () + "/kdepim/korganizer/";
+ KGlobal::iconLoader()->setIconPath(QDir::convertSeparators(fileName));
#endif
- QDir app_dir;
- if ( !app_dir.exists(KStandardDirs::appDir()) )
- app_dir.mkdir (KStandardDirs::appDir());
- MainWindow m;
+ KStandardDirs::setAppDir( QDir::convertSeparators(locateLocal("data", "korganizer")));
+ MainWindow m;
#ifndef DESKTOP_VERSION
QObject::connect( &a, SIGNAL (appMessage ( const QCString &, const QByteArray & )),&m, SLOT(recieve( const QCString&, const QByteArray& )));
a.showMainWidget(&m );