author | zautrix <zautrix> | 2004-09-12 15:24:11 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2004-09-12 15:24:11 (UTC) |
commit | a222c2f7369eeefd19454c973c0cc48300f72bec (patch) (unidiff) | |
tree | 6f01a5922ea622add6960f3fad703e8e8f099caa /gammu/emb | |
parent | b2dede5d5735e2b4ab5afd51cf6a2c46d9be9b26 (diff) | |
download | kdepimpi-a222c2f7369eeefd19454c973c0cc48300f72bec.zip kdepimpi-a222c2f7369eeefd19454c973c0cc48300f72bec.tar.gz kdepimpi-a222c2f7369eeefd19454c973c0cc48300f72bec.tar.bz2 |
many phone sync fixes
-rw-r--r-- | gammu/emb/common/service/gsmcal.c | 4 | ||||
-rw-r--r-- | gammu/emb/gammu/gammu.c | 6 |
2 files changed, 7 insertions, 3 deletions
diff --git a/gammu/emb/common/service/gsmcal.c b/gammu/emb/common/service/gsmcal.c index ddf9790..0ea8e06 100644 --- a/gammu/emb/common/service/gsmcal.c +++ b/gammu/emb/common/service/gsmcal.c | |||
@@ -475,10 +475,10 @@ GSM_Error GSM_DecodeVCALENDAR_VTODO(unsigned char *Buffer, int *Pos, GSM_Calenda | |||
475 | if (ReadVCALText(Line, "PRIORITY", Buff)) { | 475 | if (ReadVCALText(Line, "PRIORITY", Buff)) { |
476 | if (ToDoVer == SonyEricsson_VToDo) { | 476 | if (ToDoVer == SonyEricsson_VToDo) { |
477 | ToDo->Priority = GSM_Priority_Low; | 477 | ToDo->Priority = GSM_Priority_Medium; |
478 | if (atoi(DecodeUnicodeString(Buff))>3) ToDo->Priority = GSM_Priority_Low; | 478 | if (atoi(DecodeUnicodeString(Buff))>3) ToDo->Priority = GSM_Priority_Low; |
479 | if (atoi(DecodeUnicodeString(Buff))<3) ToDo->Priority = GSM_Priority_High; | 479 | if (atoi(DecodeUnicodeString(Buff))<3) ToDo->Priority = GSM_Priority_High; |
480 | dbgprintf("atoi is %i %s\n",atoi(DecodeUnicodeString(Buff)),DecodeUnicodeString(Buff)); | 480 | dbgprintf("atoi is %i %s\n",atoi(DecodeUnicodeString(Buff)),DecodeUnicodeString(Buff)); |
481 | } else if (ToDoVer == Nokia_VToDo) { | 481 | } else if (ToDoVer == Nokia_VToDo) { |
482 | ToDo->Priority = GSM_Priority_Low; | 482 | ToDo->Priority = GSM_Priority_Medium; |
483 | if (atoi(DecodeUnicodeString(Buff))>3) ToDo->Priority = GSM_Priority_Low; | 483 | if (atoi(DecodeUnicodeString(Buff))>3) ToDo->Priority = GSM_Priority_Low; |
484 | if (atoi(DecodeUnicodeString(Buff))<3) ToDo->Priority = GSM_Priority_High; | 484 | if (atoi(DecodeUnicodeString(Buff))<3) ToDo->Priority = GSM_Priority_High; |
diff --git a/gammu/emb/gammu/gammu.c b/gammu/emb/gammu/gammu.c index a3b93a8..997485a 100644 --- a/gammu/emb/gammu/gammu.c +++ b/gammu/emb/gammu/gammu.c | |||
@@ -4628,4 +4628,5 @@ static void Restore(int argc, char *argv[]) | |||
4628 | DoRestore = false; | 4628 | DoRestore = false; |
4629 | if (Backup.Calendar[0] != NULL) { | 4629 | if (Backup.Calendar[0] != NULL) { |
4630 | DoRestore = true; | ||
4630 | /* N6110 doesn't support getting calendar status */ | 4631 | /* N6110 doesn't support getting calendar status */ |
4631 | error = Phone->GetNextCalendar(&s,&Calendar,true); | 4632 | error = Phone->GetNextCalendar(&s,&Calendar,true); |
@@ -4679,4 +4680,6 @@ static void Restore(int argc, char *argv[]) | |||
4679 | error = Phone->GetToDoStatus(&s,&ToDoStatus); | 4680 | error = Phone->GetToDoStatus(&s,&ToDoStatus); |
4680 | if (error == ERR_NONE) { | 4681 | if (error == ERR_NONE) { |
4682 | error == ERR_NOTSUPPORTED; | ||
4683 | DoRestore = true; | ||
4681 | max = 0; | 4684 | max = 0; |
4682 | while (Backup.ToDo[max]!=NULL) max++; | 4685 | while (Backup.ToDo[max]!=NULL) max++; |
@@ -4687,6 +4690,8 @@ static void Restore(int argc, char *argv[]) | |||
4687 | } | 4690 | } |
4688 | if (DoRestore) { | 4691 | if (DoRestore) { |
4692 | if ( max > 0 ) { | ||
4689 | ToDo = *Backup.ToDo[0]; | 4693 | ToDo = *Backup.ToDo[0]; |
4690 | error = Phone->SetToDo(&s,&ToDo); | 4694 | error = Phone->SetToDo(&s,&ToDo); |
4695 | } | ||
4691 | } | 4696 | } |
4692 | if (DoRestore && (error == ERR_NOTSUPPORTED || error == ERR_NOTIMPLEMENTED)) { | 4697 | if (DoRestore && (error == ERR_NOTSUPPORTED || error == ERR_NOTIMPLEMENTED)) { |
@@ -8375,5 +8380,4 @@ int main(int argc, char *argv[]) | |||
8375 | } | 8380 | } |
8376 | #endif | 8381 | #endif |
8377 | argc = argc-3; | ||
8378 | 8382 | ||
8379 | 8383 | ||