author | harlekin <harlekin> | 2002-02-21 16:57:40 (UTC) |
---|---|---|
committer | harlekin <harlekin> | 2002-02-21 16:57:40 (UTC) |
commit | ec52599a5a9ca3397e6375b7aeb4ee391c614bfb (patch) (side-by-side diff) | |
tree | 5570c7a511f7d089e410a5fecadb2fee0fb73d63 /core/pim/today/today.cpp | |
parent | 4c965fa187f642cb3db4cd32d70a68cfa8c41022 (diff) | |
download | opie-ec52599a5a9ca3397e6375b7aeb4ee391c614bfb.zip opie-ec52599a5a9ca3397e6375b7aeb4ee391c614bfb.tar.gz opie-ec52599a5a9ca3397e6375b7aeb4ee391c614bfb.tar.bz2 |
all day detection, bumped to 0.2.6
-rw-r--r-- | core/pim/today/today.cpp | 35 |
1 files changed, 25 insertions, 10 deletions
diff --git a/core/pim/today/today.cpp b/core/pim/today/today.cpp index 9e5c27e..1f6f34e 100644 --- a/core/pim/today/today.cpp +++ b/core/pim/today/today.cpp @@ -189,15 +189,22 @@ void Today::getDates() // include location or not if (SHOW_LOCATION == 1) { - msg+= "<BR>" + (*it).location(); + msg+= "<BR><i>" + (*it).location(); } - msg += "<BR>" + msg += "</i><BR>"; + if ( (TimeString::timeString(QTime((*it).event().start().time()) ) == "00:00") && (TimeString::timeString(QTime((*it).event().end().time()) ) == "23:59") ) + { + msg += "All day"; + } + else + { // start time of event - + TimeString::timeString(QTime((*it).event().start().time()) ) + msg += TimeString::timeString(QTime((*it).event().start().time()) ) // end time of event - + "<b> - </b>" + TimeString::timeString(QTime((*it).event().end().time()) ) - + "<BR>"; + + "<b> - </b>" + TimeString::timeString(QTime((*it).event().end().time()) ); + } + msg += "<BR>"; // include possible note or not if (SHOW_NOTES == 1) { @@ -214,14 +221,22 @@ void Today::getDates() // include location or not if (SHOW_LOCATION == 1) { - msg+= "<BR>" + (*it).location(); + msg+= "<BR><i>" + (*it).location(); } - msg += "<BR>" + msg += "</i><BR>"; + + if ( (TimeString::timeString(QTime((*it).event().start().time()) ) == "00:00") && (TimeString::timeString(QTime((*it).event().end().time()) ) == "23:59") ) + { + msg += "All day"; + } + else + { // start time of event - + TimeString::timeString(QTime((*it).event().start().time()) ) + msg += TimeString::timeString(QTime((*it).event().start().time()) ) // end time of event - + "<b> - </b>" + TimeString::timeString(QTime((*it).event().end().time()) ) - + "<BR>"; + + "<b> - </b>" + TimeString::timeString(QTime((*it).event().end().time()) ); + } + msg += "<BR>"; // include possible note or not if (SHOW_NOTES == 1) { |