summaryrefslogtreecommitdiff
path: root/libopie
authorzecke <zecke>2003-05-07 18:10:56 (UTC)
committer zecke <zecke>2003-05-07 18:10:56 (UTC)
commit3cee83b6e2931768fb0d0989b2235800914888a7 (patch) (side-by-side diff)
treed99a7565fdb5be62cf739d82ec5de50c2bbf95e9 /libopie
parent94371938792c70a40cdb75e37c69020438d450c9 (diff)
downloadopie-3cee83b6e2931768fb0d0989b2235800914888a7.zip
opie-3cee83b6e2931768fb0d0989b2235800914888a7.tar.gz
opie-3cee83b6e2931768fb0d0989b2235800914888a7.tar.bz2
save the state
Diffstat (limited to 'libopie') (more/less context) (ignore whitespace changes)
-rw-r--r--libopie/pim/otodoaccessxml.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/libopie/pim/otodoaccessxml.cpp b/libopie/pim/otodoaccessxml.cpp
index a8e1503..285d2b8 100644
--- a/libopie/pim/otodoaccessxml.cpp
+++ b/libopie/pim/otodoaccessxml.cpp
@@ -13,12 +13,13 @@
#include <qpe/global.h>
#include <qpe/stringutil.h>
#include <qpe/timeconversion.h>
#include "oconversion.h"
+#include "opimstate.h"
#include "otimezone.h"
#include "orecur.h"
#include "otodoaccessxml.h"
namespace {
time_t rp_end;
@@ -419,12 +420,15 @@ void OTodoAccessXML::todo( QAsciiDict<int>* dict, OTodo& ev,
case OTodo::CompletedDate:
ev.setCompletedDate( OConversion::dateFromString( val ) );
break;
case OTodo::StartDate:
ev.setStartDate( OConversion::dateFromString( val ) );
break;
+ case OTodo::State:
+ ev.setState( val.toInt() );
+ break;
case OTodo::CrossReference:
{
/*
* A cross refernce looks like
* appname,id;appname,id
* we need to split it up
@@ -512,12 +516,14 @@ QString OTodoAccessXML::toString( const OTodo& ev )const {
str += ev.recurrence().toString();
}
if ( ev.hasStartDate() )
str += "StartDate=\""+ OConversion::dateToString( ev.startDate() ) +"\" ";
if ( ev.hasCompletedDate() )
str += "CompletedDate=\""+ OConversion::dateToString( ev.completedDate() ) +"\" ";
+ if ( ev.hasState() )
+ str += "State=\""+QString::number( ev.state().state() )+"\" ";
return str;
}
QString OTodoAccessXML::toString( const QArray<int>& ints ) const {
return Qtopia::Record::idsToString( ints );