summaryrefslogtreecommitdiff
path: root/libopie/pim/test/oevent_test.cpp
authorzecke <zecke>2003-02-21 16:52:49 (UTC)
committer zecke <zecke>2003-02-21 16:52:49 (UTC)
commit0bb9d0f9e7da80f0ae3b91d4ebbb7aab4d2b9df7 (patch) (side-by-side diff)
treef3ce9c9441a1073762f3e0c61cc85f0d5a1fd81d /libopie/pim/test/oevent_test.cpp
parenta298235aa1489937e7657079e6352adfc8746acf (diff)
downloadopie-0bb9d0f9e7da80f0ae3b91d4ebbb7aab4d2b9df7.zip
opie-0bb9d0f9e7da80f0ae3b91d4ebbb7aab4d2b9df7.tar.gz
opie-0bb9d0f9e7da80f0ae3b91d4ebbb7aab4d2b9df7.tar.bz2
-Remove old Todo classes they're deprecated and today I already using the
new API -Guard against self assignment in OTodo -Add test apps for OPIM -Opiefied Event classes -Added TimeZone handling and pinning of TimeZones to OEvent -Adjust ORecur and the widget to better timezone behaviour
Diffstat (limited to 'libopie/pim/test/oevent_test.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--libopie/pim/test/oevent_test.cpp23
1 files changed, 23 insertions, 0 deletions
diff --git a/libopie/pim/test/oevent_test.cpp b/libopie/pim/test/oevent_test.cpp
new file mode 100644
index 0000000..50cc032
--- a/dev/null
+++ b/libopie/pim/test/oevent_test.cpp
@@ -0,0 +1,23 @@
+#include <qdatetime.h>
+
+#include "../oevent.h"
+
+int main(int argc, char* argv ) {
+ OEvent ev;
+ ev.setUid( 20 );
+
+ ev.setDescription( "Foo" );
+
+ OEvent ev2 = ev;
+ ev2.setDescription("Foo2");
+ qWarning("%s", ev2.description().latin1() );
+ qWarning("%s", ev.description().latin1() );
+
+ QDateTime time = QDateTime::currentDateTime();
+ ev2.setStartDateTime( time );
+ ev2.setTimeZone( "Europe/London" );
+
+ qWarning("%s", ev2.startDateTime().toString().latin1() );
+ qWarning("%s", ev2.startDateTimeInZone().toString().latin1() );
+ return 0;
+}