summaryrefslogtreecommitdiff
path: root/library/backend/event.cpp
Side-by-side diff
Diffstat (limited to 'library/backend/event.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--library/backend/event.cpp9
1 files changed, 7 insertions, 2 deletions
diff --git a/library/backend/event.cpp b/library/backend/event.cpp
index 7110717..8f3f780 100644
--- a/library/backend/event.cpp
+++ b/library/backend/event.cpp
@@ -421,13 +421,13 @@ int Event::monthDiff( const QDate& first, const QDate& second )
QMap<int, QString> Event::toMap() const
{
QMap<int, QString> m;
if ( !description().isEmpty() )
m.insert( DatebookDescription, description() );
- if ( !location().isEmpty() )
+ if ( !location().isEmpty() )
m.insert ( Location, location() );
if ( categories().count() )
m.insert ( DatebookCategory, idsToString( categories() ) );
if ( !timeZone().isEmpty() )
m.insert ( TimeZone, timeZone() );
if ( !notes().isEmpty() )
@@ -582,13 +582,15 @@ const QString &Event::location() const
\internal
*/
Event::Type Event::type() const
{
return typ;
}
-
+QDateTime Event::start() const {
+ return start( TRUE );
+}
/*!
\internal
*/
QDateTime Event::start( bool actual ) const
{
QDateTime dt = (startUTC > 0) ? TimeConversion::fromUTC( startUTC ) : QDateTime::currentDateTime();
@@ -598,12 +600,15 @@ QDateTime Event::start( bool actual ) const
t.setHMS( 0, 0, 0 );
dt.setTime( t );
}
return dt;
}
+QDateTime Event::end() const {
+ return end( TRUE );
+}
/*!
\internal
*/
QDateTime Event::end( bool actual ) const
{
QDateTime dt = (endUTC > 0) ? TimeConversion::fromUTC( endUTC ) : QDateTime::currentDateTime();