summaryrefslogtreecommitdiff
path: root/libopie2/opiepim/core/opimevent.cpp
Unidiff
Diffstat (limited to 'libopie2/opiepim/core/opimevent.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--libopie2/opiepim/core/opimevent.cpp24
1 files changed, 13 insertions, 11 deletions
diff --git a/libopie2/opiepim/core/opimevent.cpp b/libopie2/opiepim/core/opimevent.cpp
index 9d46651..8752fce 100644
--- a/libopie2/opiepim/core/opimevent.cpp
+++ b/libopie2/opiepim/core/opimevent.cpp
@@ -35,2 +35,4 @@
35#include <opie2/opimnotifymanager.h> 35#include <opie2/opimnotifymanager.h>
36#include <opie2/odebug.h>
37
36#include <qpe/categories.h> 38#include <qpe/categories.h>
@@ -557,7 +559,7 @@ QMap<int, QString> OPimEvent::toMap() const
557 retMap.insert( OPimEvent::FType, isAllDay() ? "AllDay" : "" ); 559 retMap.insert( OPimEvent::FType, isAllDay() ? "AllDay" : "" );
558 if ( notifiers().alarms().count() ){ 560 if ( notifiers().alarms().count() ){
559 // Currently we just support one alarm.. (eilers) 561 // Currently we just support one alarm.. (eilers)
560 OPimAlarm alarm = notifiers().alarms() [ 0 ]; 562 OPimAlarm alarm = notifiers().alarms() [ 0 ];
561 retMap.insert( OPimEvent::FAlarm, QString::number( alarm.dateTime().secsTo( startDateTime() ) / 60 ) ); 563 retMap.insert( OPimEvent::FAlarm, QString::number( alarm.dateTime().secsTo( startDateTime() ) / 60 ) );
562 retMap.insert( OPimEvent::FSound, ( alarm.sound() == OPimAlarm::Loud ) ? "loud" : "silent" ); 564 retMap.insert( OPimEvent::FSound, ( alarm.sound() == OPimAlarm::Loud ) ? "loud" : "silent" );
563 } 565 }
@@ -643,6 +645,6 @@ void OPimEvent::fromMap( const QMap<int, QString>& map )
643 /* to current date time */ 645 /* to current date time */
644 // qWarning(" Start is %d", start ); 646 // owarn << " Start is " << start << "" << oendl;
645 OPimTimeZone zone( timeZone().isEmpty() ? OPimTimeZone::current() : timeZone() ); 647 OPimTimeZone zone( timeZone().isEmpty() ? OPimTimeZone::current() : timeZone() );
646 QDateTime date = zone.toDateTime( start ); 648 QDateTime date = zone.toDateTime( start );
647 qWarning( " Start is %s", date.toString().latin1() ); 649 owarn << " Start is " << date.toString() << "" << oendl;
648 setStartDateTime( zone.toDateTime( date, OPimTimeZone::current() ) ); 650 setStartDateTime( zone.toDateTime( date, OPimTimeZone::current() ) );
@@ -660,5 +662,5 @@ void OPimEvent::fromMap( const QMap<int, QString>& map )
660 { 662 {
661 QDateTime dt = startDateTime().addSecs( -1 * alarmTime * 60 ); 663 QDateTime dt = startDateTime().addSecs( -1 * alarmTime * 60 );
662 OPimAlarm al( sound , dt ); 664 OPimAlarm al( sound , dt );
663 notifiers().add( al ); 665 notifiers().add( al );
664 } 666 }
@@ -667,3 +669,3 @@ void OPimEvent::fromMap( const QMap<int, QString>& map )
667 if ( !map[ OPimEvent::FNote ].isEmpty() ) 669 if ( !map[ OPimEvent::FNote ].isEmpty() )
668 setNote( map[ OPimEvent::FNote ] ); 670 setNote( map[ OPimEvent::FNote ] );
669 671