summaryrefslogtreecommitdiffabout
path: root/pwmanager
authorulf69 <ulf69>2004-10-29 01:27:31 (UTC)
committer ulf69 <ulf69>2004-10-29 01:27:31 (UTC)
commitf8dd437160acec2959c462dd43d87f2a0920c0b9 (patch) (unidiff)
treeddd271930f54adc1b7220d534f682f616efeb20a /pwmanager
parent1b8d173d880e8f681bca88220bdd806a95d3c2a0 (diff)
downloadkdepimpi-f8dd437160acec2959c462dd43d87f2a0920c0b9.zip
kdepimpi-f8dd437160acec2959c462dd43d87f2a0920c0b9.tar.gz
kdepimpi-f8dd437160acec2959c462dd43d87f2a0920c0b9.tar.bz2
enabling/disabling syncing of launcher
Diffstat (limited to 'pwmanager') (more/less context) (ignore whitespace changes)
-rw-r--r--pwmanager/pwmanager/pwmdoc.cpp10
-rw-r--r--pwmanager/pwmanager/pwmdoc.h20
2 files changed, 24 insertions, 6 deletions
diff --git a/pwmanager/pwmanager/pwmdoc.cpp b/pwmanager/pwmanager/pwmdoc.cpp
index fd17ce5..9043acc 100644
--- a/pwmanager/pwmanager/pwmdoc.cpp
+++ b/pwmanager/pwmanager/pwmdoc.cpp
@@ -3022,2 +3022,4 @@ PwMerror PwMDoc::syncronize(KSyncManager* manager, PwMDoc* syncLocal , PwMDoc* s
3022 3022
3023 bool mSyncLauncher = true;
3024
3023 bool fullDateRange = false; 3025 bool fullDateRange = false;
@@ -3122,10 +3124,6 @@ PwMerror PwMDoc::syncronize(KSyncManager* manager, PwMDoc* syncLocal , PwMDoc* s
3122 if ( take == 1 ) {// take local 3124 if ( take == 1 ) {// take local
3123 int oldlistpos = inRemote->listViewPos; 3125 inRemote->syncItem(*inLocal, mSyncLauncher);
3124 (*inRemote) = (*inLocal);
3125 inRemote->listViewPos = oldlistpos;
3126 ++changedRemote; 3126 ++changedRemote;
3127 } else { // take == 2 take remote 3127 } else { // take == 2 take remote
3128 int oldlistpos = inLocal->listViewPos; 3128 inLocal->syncItem(*inRemote, mSyncLauncher);
3129 (*inLocal) = (*inRemote);
3130 inLocal->listViewPos = oldlistpos;
3131 ++changedLocal; 3129 ++changedLocal;
diff --git a/pwmanager/pwmanager/pwmdoc.h b/pwmanager/pwmanager/pwmdoc.h
index e419c24..09923ab 100644
--- a/pwmanager/pwmanager/pwmdoc.h
+++ b/pwmanager/pwmanager/pwmdoc.h
@@ -226,2 +226,22 @@ struct PwMDataItem
226 } 226 }
227
228 //US ENH: this sync method actually copies all values from the parameter like the =operator
229 //does with two exceptions: listViewPos will not be changed, and the launcher only if required.
230 bool PwMDataItem::syncItem(const PwMDataItem &a, bool syncLauncher=true )
231 {
232 desc = a.desc;
233 name = a.name;
234 pw = a.pw;
235 comment = a.comment;
236 url = a.url;
237 if (syncLauncher == true)
238 launcher = a.launcher;
239 meta = a.meta;
240 binary = a.binary;
241 lockStat = a.lockStat;
242 rev = a.rev;
243
244 return true;
245 }
246
227}; 247};