summaryrefslogtreecommitdiffabout
Unidiff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--korganizer/mainwindow.cpp10
-rw-r--r--libkdepim/libkdepim.pro2
-rw-r--r--microkde/kdecore/kstandarddirs.cpp27
3 files changed, 27 insertions, 12 deletions
diff --git a/korganizer/mainwindow.cpp b/korganizer/mainwindow.cpp
index f4ac0d6..7bf33d3 100644
--- a/korganizer/mainwindow.cpp
+++ b/korganizer/mainwindow.cpp
@@ -860,31 +860,31 @@ void MainWindow::initActions()
860 QWhatsThis::whatsThisButton ( iconToolBar ); 860 QWhatsThis::whatsThisButton ( iconToolBar );
861 connect( configureToolBarMenu, SIGNAL( activated( int ) ),this, SLOT(configureToolBar( int ) ) ); 861 connect( configureToolBarMenu, SIGNAL( activated( int ) ),this, SLOT(configureToolBar( int ) ) );
862 configureAgenda( p->mHourSize ); 862 configureAgenda( p->mHourSize );
863 connect( configureAgendaMenu, SIGNAL( activated( int ) ),this, SLOT(configureAgenda( int ) ) ); 863 connect( configureAgendaMenu, SIGNAL( activated( int ) ),this, SLOT(configureAgenda( int ) ) );
864} 864}
865void MainWindow::fillSyncMenu() 865void MainWindow::fillSyncMenu()
866{ 866{
867 if ( syncMenu->count() ) 867 if ( syncMenu->count() )
868 syncMenu->clear(); 868 syncMenu->clear();
869 syncMenu->insertItem( i18n("Configure..."), 0 ); 869 syncMenu->insertItem( i18n("Configure..."), 0 );
870 syncMenu->insertSeparator(); 870 syncMenu->insertSeparator();
871 if ( mServerSocket == 0 ) { 871 if ( mServerSocket == 0 ) {
872 syncMenu->insertItem( i18n("Enable Easy-Pi-Sync"), 2 ); 872 syncMenu->insertItem( i18n("Enable Pi-Sync"), 2 );
873 } else { 873 } else {
874 syncMenu->insertItem( i18n("Disable Easy-Pi-Sync"), 3 ); 874 syncMenu->insertItem( i18n("Disable Pi-Sync"), 3 );
875 } 875 }
876 syncMenu->insertSeparator(); 876 syncMenu->insertSeparator();
877 syncMenu->insertItem( i18n("New Easy-Pi-Sync!"), 4 ); 877 syncMenu->insertItem( i18n("New Pi-Sync!"), 4 );
878 syncMenu->insertItem( i18n("Quick Easy-Pi-Sync!"), 5 ); 878 syncMenu->insertItem( i18n("Quick Pi-Sync!"), 5 );
879 syncMenu->insertSeparator(); 879 syncMenu->insertSeparator();
880 syncMenu->insertItem( i18n("Multiple sync"), 1 ); 880 syncMenu->insertItem( i18n("Multiple sync"), 1 );
881 syncMenu->insertSeparator(); 881 syncMenu->insertSeparator();
882 KConfig config ( locateLocal( "config","ksyncprofilesrc" ) ); 882 KConfig config ( locateLocal( "config","ksyncprofilesrc" ) );
883 config.setGroup("General"); 883 config.setGroup("General");
884 QStringList prof = config.readListEntry("SyncProfileNames"); 884 QStringList prof = config.readListEntry("SyncProfileNames");
885 KOPrefs::instance()->mLocalMachineName = config.readEntry("LocalMachineName","undefined"); 885 KOPrefs::instance()->mLocalMachineName = config.readEntry("LocalMachineName","undefined");
886 if ( prof.count() < 3 ) { 886 if ( prof.count() < 3 ) {
887 prof.clear(); 887 prof.clear();
888 prof << i18n("Sharp_DTM"); 888 prof << i18n("Sharp_DTM");
889 prof << i18n("Local_file"); 889 prof << i18n("Local_file");
890 prof << i18n("Last_file"); 890 prof << i18n("Last_file");
@@ -1998,25 +1998,27 @@ void MainWindow::getFile(QSocket* socket)
1998 while ( socket->canReadLine () ) { 1998 while ( socket->canReadLine () ) {
1999 qDebug("avail %d ", socket->bytesAvailable () ); 1999 qDebug("avail %d ", socket->bytesAvailable () );
2000 ts << socket->readLine (); 2000 ts << socket->readLine ();
2001 } 2001 }
2002 QTime ti; 2002 QTime ti;
2003 ti.start(); 2003 ti.start();
2004 while ( ti.elapsed () < 5000 && !socket->canReadLine () ) { 2004 while ( ti.elapsed () < 5000 && !socket->canReadLine () ) {
2005 qDebug("waiting1a %d %d ",ti.elapsed (), socket->bytesAvailable () ); 2005 qDebug("waiting1a %d %d ",ti.elapsed (), socket->bytesAvailable () );
2006 //qApp->processEvents(); 2006 //qApp->processEvents();
2007 qDebug("waiting1b %d ",ti.elapsed () ); 2007 qDebug("waiting1b %d ",ti.elapsed () );
2008 if ( !socket->canReadLine () ) { 2008 if ( !socket->canReadLine () ) {
2009 qDebug("waiting1c %d ",ti.elapsed () ); 2009 qDebug("waiting1c %d ",ti.elapsed () );
2010#ifndef _WIN32_
2010 usleep( 100000); 2011 usleep( 100000);
2012#endif
2011 } 2013 }
2012 //socket->waitForMore ( 100 ); 2014 //socket->waitForMore ( 100 );
2013 } 2015 }
2014 ts << socket->readLine (); 2016 ts << socket->readLine ();
2015#if 0 2017#if 0
2016#ifdef DESKTOP_VERSION 2018#ifdef DESKTOP_VERSION
2017 socket->waitForMore ( 5000 ); 2019 socket->waitForMore ( 5000 );
2018#else 2020#else
2019 // socket->waitForMore ( 5000 ); 2021 // socket->waitForMore ( 5000 );
2020 // seems to be broken in qt2 2022 // seems to be broken in qt2
2021 bool stop = false; 2023 bool stop = false;
2022 QTime ti; 2024 QTime ti;
diff --git a/libkdepim/libkdepim.pro b/libkdepim/libkdepim.pro
index 7231842..eac19ea 100644
--- a/libkdepim/libkdepim.pro
+++ b/libkdepim/libkdepim.pro
@@ -22,36 +22,38 @@ HEADERS = \
22 categoryeditdialog.h \ 22 categoryeditdialog.h \
23 categoryeditdialog_base.h \ 23 categoryeditdialog_base.h \
24 categoryselectdialog.h \ 24 categoryselectdialog.h \
25 categoryselectdialog_base.h \ 25 categoryselectdialog_base.h \
26 externalapphandler.h \ 26 externalapphandler.h \
27 kdateedit.h \ 27 kdateedit.h \
28 kdatepicker.h \ 28 kdatepicker.h \
29 kinputdialog.h \ 29 kinputdialog.h \
30 kpimprefs.h \ 30 kpimprefs.h \
31 kpimglobalprefs.h \ 31 kpimglobalprefs.h \
32 kprefsdialog.h \ 32 kprefsdialog.h \
33 kprefswidget.h \ 33 kprefswidget.h \
34 ksyncmanager.h \
34 ksyncprofile.h \ 35 ksyncprofile.h \
35 ksyncprefsdialog.h \ 36 ksyncprefsdialog.h \
36 kcmconfigs/kcmkdepimconfig.h \ 37 kcmconfigs/kcmkdepimconfig.h \
37 kcmconfigs/kdepimconfigwidget.h 38 kcmconfigs/kdepimconfigwidget.h
38 39
39SOURCES = \ 40SOURCES = \
40 categoryeditdialog.cpp \ 41 categoryeditdialog.cpp \
41 categoryeditdialog_base.cpp \ 42 categoryeditdialog_base.cpp \
42 categoryselectdialog.cpp \ 43 categoryselectdialog.cpp \
43 categoryselectdialog_base.cpp \ 44 categoryselectdialog_base.cpp \
44 externalapphandler.cpp \ 45 externalapphandler.cpp \
45 kdateedit.cpp \ 46 kdateedit.cpp \
46 kdatepicker.cpp \ 47 kdatepicker.cpp \
47 kinputdialog.cpp \ 48 kinputdialog.cpp \
48 kpimprefs.cpp \ 49 kpimprefs.cpp \
49 kpimglobalprefs.cpp \ 50 kpimglobalprefs.cpp \
50 kprefsdialog.cpp \ 51 kprefsdialog.cpp \
51 kprefswidget.cpp \ 52 kprefswidget.cpp \
53 ksyncmanager.cpp \
52 ksyncprofile.cpp \ 54 ksyncprofile.cpp \
53 ksyncprefsdialog.cpp \ 55 ksyncprefsdialog.cpp \
54 kcmconfigs/kcmkdepimconfig.cpp \ 56 kcmconfigs/kcmkdepimconfig.cpp \
55 kcmconfigs/kdepimconfigwidget.cpp 57 kcmconfigs/kdepimconfigwidget.cpp
56 58
57 59
diff --git a/microkde/kdecore/kstandarddirs.cpp b/microkde/kdecore/kstandarddirs.cpp
index 7f2a326..1c3e0ae 100644
--- a/microkde/kdecore/kstandarddirs.cpp
+++ b/microkde/kdecore/kstandarddirs.cpp
@@ -33,24 +33,25 @@
33//US #include <sys/stat.h> 33//US #include <sys/stat.h>
34//US #endif 34//US #endif
35//US#include <sys/types.h> 35//US#include <sys/types.h>
36//US#include <dirent.h> 36//US#include <dirent.h>
37//US#include <pwd.h> 37//US#include <pwd.h>
38 38
39#include <qregexp.h> 39#include <qregexp.h>
40#include <qasciidict.h> 40#include <qasciidict.h>
41#include <qdict.h> 41#include <qdict.h>
42#include <qdir.h> 42#include <qdir.h>
43#include <qfileinfo.h> 43#include <qfileinfo.h>
44#include <qstring.h> 44#include <qstring.h>
45#include <qmessagebox.h>
45#include <qapplication.h> 46#include <qapplication.h>
46 47
47#include <qstringlist.h> 48#include <qstringlist.h>
48 49
49#include "kstandarddirs.h" 50#include "kstandarddirs.h"
50#include "kconfig.h" 51#include "kconfig.h"
51#include "kdebug.h" 52#include "kdebug.h"
52//US #include "kinstance.h" 53//US #include "kinstance.h"
53#include "kshell.h" 54#include "kshell.h"
54//US#include <sys/param.h> 55//US#include <sys/param.h>
55//US#include <unistd.h> 56//US#include <unistd.h>
56 57
@@ -1195,36 +1196,40 @@ bool KStandardDirs::makeDir(const QString& dir2, int mode)
1195 return false; 1196 return false;
1196 } 1197 }
1197 } 1198 }
1198 1199
1199 i = pos + 1; 1200 i = pos + 1;
1200 } 1201 }
1201 return true; 1202 return true;
1202 1203
1203} 1204}
1204 1205
1205static QString readEnvPath(const char *env) 1206static QString readEnvPath(const char *env)
1206{ 1207{
1207#ifdef _WIN32_ 1208 //#ifdef _WIN32_
1208 return ""; 1209 // return "";
1209#else 1210 //#else
1210 QCString c_path = getenv(env); 1211 QCString c_path;
1211 if (c_path.isEmpty()) 1212 if ( getenv(env) != NULL )
1212 return QString::null; 1213 c_path = QString ( getenv(env) );
1213 return QFile::decodeName(c_path); 1214 if (c_path.isEmpty())
1214#endif 1215 return QString::null;
1216 return QFile::decodeName(c_path);
1217 //#endif
1218
1215} 1219}
1216 1220
1217void KStandardDirs::addKDEDefaults() 1221void KStandardDirs::addKDEDefaults()
1218{ 1222{
1223
1219 //qDebug("ERROR: KStandardDirs::addKDEDefaults() called "); 1224 //qDebug("ERROR: KStandardDirs::addKDEDefaults() called ");
1220 //return; 1225 //return;
1221 QStringList kdedirList; 1226 QStringList kdedirList;
1222 1227
1223 // begin KDEDIRS 1228 // begin KDEDIRS
1224 QString kdedirs = readEnvPath("MICROKDEDIRS"); 1229 QString kdedirs = readEnvPath("MICROKDEDIRS");
1225 if (!kdedirs.isEmpty()) 1230 if (!kdedirs.isEmpty())
1226 { 1231 {
1227 tokenize(kdedirList, kdedirs, ":"); 1232 tokenize(kdedirList, kdedirs, ":");
1228 } 1233 }
1229 else 1234 else
1230 { 1235 {
@@ -1258,26 +1263,32 @@ void KStandardDirs::addKDEDefaults()
1258 if (execPrefix!="NONE") 1263 if (execPrefix!="NONE")
1259 kdedirList.append(execPrefix); 1264 kdedirList.append(execPrefix);
1260#endif 1265#endif
1261 1266
1262 QString localKdeDir; 1267 QString localKdeDir;
1263 1268
1264//US if (getuid()) 1269//US if (getuid())
1265 if (true) 1270 if (true)
1266 { 1271 {
1267 localKdeDir = readEnvPath("MICROKDEHOME"); 1272 localKdeDir = readEnvPath("MICROKDEHOME");
1268 if (!localKdeDir.isEmpty()) 1273 if (!localKdeDir.isEmpty())
1269 { 1274 {
1275#ifdef _WIN32_
1276 if (localKdeDir.at(localKdeDir.length()-1) != '\\')
1277 localKdeDir += '\\';
1278#else
1270 if (localKdeDir.at(localKdeDir.length()-1) != '/') 1279 if (localKdeDir.at(localKdeDir.length()-1) != '/')
1271 localKdeDir += '/'; 1280 localKdeDir += '/';
1281#endif
1282 //QMessageBox::information( 0,"localKdeDir",localKdeDir, 1 );
1272 } 1283 }
1273 else 1284 else
1274 { 1285 {
1275 localKdeDir = QDir::homeDirPath() + "/kdepim/"; 1286 localKdeDir = QDir::homeDirPath() + "/kdepim/";
1276 } 1287 }
1277 } 1288 }
1278 else 1289 else
1279 { 1290 {
1280 // We treat root different to prevent root messing up the 1291 // We treat root different to prevent root messing up the
1281 // file permissions in the users home directory. 1292 // file permissions in the users home directory.
1282 localKdeDir = readEnvPath("MICROKDEROOTHOME"); 1293 localKdeDir = readEnvPath("MICROKDEROOTHOME");
1283 if (!localKdeDir.isEmpty()) 1294 if (!localKdeDir.isEmpty())