summaryrefslogtreecommitdiff
path: root/libopie2/opiepim/backend/otodoaccessvcal.cpp
Unidiff
Diffstat (limited to 'libopie2/opiepim/backend/otodoaccessvcal.cpp') (more/less context) (show whitespace changes)
-rw-r--r--libopie2/opiepim/backend/otodoaccessvcal.cpp10
1 files changed, 7 insertions, 3 deletions
diff --git a/libopie2/opiepim/backend/otodoaccessvcal.cpp b/libopie2/opiepim/backend/otodoaccessvcal.cpp
index 03d4479..14a325e 100644
--- a/libopie2/opiepim/backend/otodoaccessvcal.cpp
+++ b/libopie2/opiepim/backend/otodoaccessvcal.cpp
@@ -18,29 +18,33 @@
18 _.=:. : :=>`: PARTICULAR PURPOSE. See the GNU 18 _.=:. : :=>`: PARTICULAR PURPOSE. See the GNU
19..}^=.= = ; Library General Public License for more 19..}^=.= = ; Library General Public License for more
20++= -. .` .: details. 20++= -. .` .: details.
21 : = ...= . :.=- 21 : = ...= . :.=-
22 -. .:....=;==+<; You should have received a copy of the GNU 22 -. .:....=;==+<; You should have received a copy of the GNU
23 -_. . . )=. = Library General Public License along with 23 -_. . . )=. = Library General Public License along with
24 -- :-=` this library; see the file COPYING.LIB. 24 -- :-=` this library; see the file COPYING.LIB.
25 If not, write to the Free Software Foundation, 25 If not, write to the Free Software Foundation,
26 Inc., 59 Temple Place - Suite 330, 26 Inc., 59 Temple Place - Suite 330,
27 Boston, MA 02111-1307, USA. 27 Boston, MA 02111-1307, USA.
28*/ 28*/
29 29
30/* OPIE */
31#include "vobject_p.h" 30#include "vobject_p.h"
32#include <qpe/timeconversion.h> 31
32/* OPIE */
33#include <opie2/otodoaccessvcal.h> 33#include <opie2/otodoaccessvcal.h>
34#include <opie2/odebug.h>
35
36#include <qpe/timeconversion.h>
34 37
38/* QT */
35//FIXME: Hack to allow direct access to FILE* fh. Rewrite this! 39//FIXME: Hack to allow direct access to FILE* fh. Rewrite this!
36#define protected public 40#define protected public
37#include <qfile.h> 41#include <qfile.h>
38#undef protected 42#undef protected
39 43
40using namespace Opie; 44using namespace Opie;
41 45
42namespace { 46namespace {
43 static OPimTodo eventByVObj( VObject *obj ){ 47 static OPimTodo eventByVObj( VObject *obj ){
44 OPimTodo event; 48 OPimTodo event;
45 VObject *ob; 49 VObject *ob;
46 QCString name; 50 QCString name;
@@ -79,25 +83,25 @@ namespace {
79 bool ok; 83 bool ok;
80 event.setPriority(name.toInt(&ok) ); 84 event.setPriority(name.toInt(&ok) );
81 } 85 }
82 //due date 86 //due date
83 if((ob = isAPropertyOf(obj, VCDueProp)) ){ 87 if((ob = isAPropertyOf(obj, VCDueProp)) ){
84 event.setHasDueDate( true ); 88 event.setHasDueDate( true );
85 name = vObjectStringZValue( ob ); 89 name = vObjectStringZValue( ob );
86 event.setDueDate( TimeConversion::fromISO8601( name).date() ); 90 event.setDueDate( TimeConversion::fromISO8601( name).date() );
87 } 91 }
88 // categories 92 // categories
89 if((ob = isAPropertyOf( obj, VCCategoriesProp )) != 0 ){ 93 if((ob = isAPropertyOf( obj, VCCategoriesProp )) != 0 ){
90 name = vObjectStringZValue( ob ); 94 name = vObjectStringZValue( ob );
91 qWarning("Categories:%s", name.data() ); 95 owarn << "Categories:" << name.data() << "" << oendl;
92 } 96 }
93 97
94 event.setUid( 1 ); 98 event.setUid( 1 );
95 return event; 99 return event;
96 }; 100 };
97 static VObject *vobjByEvent( const OPimTodo &event ) { 101 static VObject *vobjByEvent( const OPimTodo &event ) {
98 VObject *task = newVObject( VCTodoProp ); 102 VObject *task = newVObject( VCTodoProp );
99 if( task == 0 ) 103 if( task == 0 )
100 return 0l; 104 return 0l;
101 105
102 if( event.hasDueDate() ) { 106 if( event.hasDueDate() ) {
103 QTime time(0, 0, 0); 107 QTime time(0, 0, 0);