Diffstat (limited to 'libopie2/opiepim/backend/ocontactaccessbackend_vcard.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | libopie2/opiepim/backend/ocontactaccessbackend_vcard.cpp | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/libopie2/opiepim/backend/ocontactaccessbackend_vcard.cpp b/libopie2/opiepim/backend/ocontactaccessbackend_vcard.cpp index 622d40a..e537269 100644 --- a/libopie2/opiepim/backend/ocontactaccessbackend_vcard.cpp +++ b/libopie2/opiepim/backend/ocontactaccessbackend_vcard.cpp | |||
@@ -8,24 +8,33 @@ | |||
8 | *This program is free software; you can redistribute it and/or | 8 | *This program is free software; you can redistribute it and/or |
9 | *modify it under the terms of the GNU Library General Public | 9 | *modify it under the terms of the GNU Library General Public |
10 | * License as published by the Free Software Foundation; either | 10 | * License as published by the Free Software Foundation; either |
11 | * version 2 of the License, or (at your option) any later version. | 11 | * version 2 of the License, or (at your option) any later version. |
12 | * ===================================================================== | 12 | * ===================================================================== |
13 | * ToDo: | 13 | * ToDo: |
14 | * | 14 | * |
15 | * ===================================================================== | 15 | * ===================================================================== |
16 | * Version: $Id$ | 16 | * Version: $Id$ |
17 | * ===================================================================== | 17 | * ===================================================================== |
18 | * History: | 18 | * History: |
19 | * $Log$ | 19 | * $Log$ |
20 | * Revision 1.8 2003/02/21 16:52:49 zecke | ||
21 | * -Remove old Todo classes they're deprecated and today I already using the | ||
22 | * new API | ||
23 | * -Guard against self assignment in OTodo | ||
24 | * -Add test apps for OPIM | ||
25 | * -Opiefied Event classes | ||
26 | * -Added TimeZone handling and pinning of TimeZones to OEvent | ||
27 | * -Adjust ORecur and the widget to better timezone behaviour | ||
28 | * | ||
20 | * Revision 1.7 2003/02/16 22:25:46 zecke | 29 | * Revision 1.7 2003/02/16 22:25:46 zecke |
21 | * 0000276 Fix for that bug.. or better temp workaround | 30 | * 0000276 Fix for that bug.. or better temp workaround |
22 | * A Preferred Number is HOME|VOICE | 31 | * A Preferred Number is HOME|VOICE |
23 | * A CellPhone is HOME|VOICE|CELL the type & HOME|VOICE test | 32 | * A CellPhone is HOME|VOICE|CELL the type & HOME|VOICE test |
24 | * triggers both | 33 | * triggers both |
25 | * and the cell phone number overrides the other entries.. | 34 | * and the cell phone number overrides the other entries.. |
26 | * | 35 | * |
27 | * as a temp I check that it's not equal to HOME|VOICE|CELL before setting the | 36 | * as a temp I check that it's not equal to HOME|VOICE|CELL before setting the |
28 | * number | 37 | * number |
29 | * | 38 | * |
30 | * The right and final fix would be to reorder the if statement to make it | 39 | * The right and final fix would be to reorder the if statement to make it |
31 | * if else based and the less common thing put to the bottom | 40 | * if else based and the less common thing put to the bottom |
@@ -65,25 +74,25 @@ OContactAccessBackend_VCard::OContactAccessBackend_VCard ( QString , QString fil | |||
65 | { | 74 | { |
66 | load(); | 75 | load(); |
67 | } | 76 | } |
68 | 77 | ||
69 | 78 | ||
70 | bool OContactAccessBackend_VCard::load () | 79 | bool OContactAccessBackend_VCard::load () |
71 | { | 80 | { |
72 | m_map.clear(); | 81 | m_map.clear(); |
73 | m_dirty = false; | 82 | m_dirty = false; |
74 | 83 | ||
75 | VObject* obj = 0l; | 84 | VObject* obj = 0l; |
76 | 85 | ||
77 | if ( QFile( m_file ).exists() ){ | 86 | if ( QFile::exists(m_file) ){ |
78 | obj = Parse_MIME_FromFileName( QFile::encodeName(m_file).data() ); | 87 | obj = Parse_MIME_FromFileName( QFile::encodeName(m_file).data() ); |
79 | if ( !obj ) | 88 | if ( !obj ) |
80 | return false; | 89 | return false; |
81 | }else{ | 90 | }else{ |
82 | qWarning("File \"%s\" not found !", m_file.latin1() ); | 91 | qWarning("File \"%s\" not found !", m_file.latin1() ); |
83 | return false; | 92 | return false; |
84 | } | 93 | } |
85 | 94 | ||
86 | while ( obj ) { | 95 | while ( obj ) { |
87 | OContact con = parseVObject( obj ); | 96 | OContact con = parseVObject( obj ); |
88 | /* | 97 | /* |
89 | * if uid is 0 assign a new one | 98 | * if uid is 0 assign a new one |