summaryrefslogtreecommitdiffabout
path: root/kabc/plugins/dir
authorzautrix <zautrix>2004-09-15 10:22:55 (UTC)
committer zautrix <zautrix>2004-09-15 10:22:55 (UTC)
commitd4adafe41cf399585b8e35cb600ff35706d55ae0 (patch) (side-by-side diff)
tree1becc87f6c40390fd73082996d18f71fb5e9c772 /kabc/plugins/dir
parent8889ffd6f6958c3a1d07bafedcc8af5d786a1660 (diff)
downloadkdepimpi-d4adafe41cf399585b8e35cb600ff35706d55ae0.zip
kdepimpi-d4adafe41cf399585b8e35cb600ff35706d55ae0.tar.gz
kdepimpi-d4adafe41cf399585b8e35cb600ff35706d55ae0.tar.bz2
fixes for desktop version
Diffstat (limited to 'kabc/plugins/dir') (more/less context) (ignore whitespace changes)
-rw-r--r--kabc/plugins/dir/resourcedir.cpp17
-rw-r--r--kabc/plugins/dir/resourcedir.h3
2 files changed, 13 insertions, 7 deletions
diff --git a/kabc/plugins/dir/resourcedir.cpp b/kabc/plugins/dir/resourcedir.cpp
index 7d96cb7..e58e4f7 100644
--- a/kabc/plugins/dir/resourcedir.cpp
+++ b/kabc/plugins/dir/resourcedir.cpp
@@ -58,2 +58,3 @@ $Id$
+#define NO_DIRWATCH
#include "resourcedir.h"
@@ -115,3 +116,3 @@ ResourceDir::ResourceDir( const KConfig *config, bool syncable )
*/
-
+#ifndef NO_DIRWATCH
connect( &mDirWatch, SIGNAL( dirty(const QString&) ), SLOT( pathChanged() ) );
@@ -119,3 +120,3 @@ ResourceDir::ResourceDir( const KConfig *config, bool syncable )
connect( &mDirWatch, SIGNAL( deleted(const QString&) ), SLOT( pathChanged() ) );
-
+#endif
setPath( path );
@@ -210,5 +211,5 @@ bool ResourceDir::save( Ticket *ticket )
bool ok = true;
-
+#ifndef NO_DIRWATCH
mDirWatch.stopScan();
-
+#endif
for ( it = addressBook()->begin(); it != addressBook()->end(); ++it ) {
@@ -230,4 +231,5 @@ bool ResourceDir::save( Ticket *ticket )
}
+#ifndef NO_DIRWATCH
mDirWatch.startScan();
-
+#endif
delete ticket;
@@ -303,2 +305,3 @@ void ResourceDir::setPath( const QString &path )
{
+#ifndef NO_DIRWATCH
mDirWatch.stopScan();
@@ -310,3 +313,5 @@ void ResourceDir::setPath( const QString &path )
mDirWatch.startScan();
-
+#else
+ mPath = path;
+#endif
//US simulate KDirWatch event
diff --git a/kabc/plugins/dir/resourcedir.h b/kabc/plugins/dir/resourcedir.h
index c2aedad..77cd18c 100644
--- a/kabc/plugins/dir/resourcedir.h
+++ b/kabc/plugins/dir/resourcedir.h
@@ -106,4 +106,5 @@ private:
+#ifndef NO_DIRWATCH
KDirWatch mDirWatch;
-
+#endif
QString mPath;