summaryrefslogtreecommitdiffabout
path: root/korganizer/komonthview.cpp
authorzautrix <zautrix>2005-10-27 23:22:36 (UTC)
committer zautrix <zautrix>2005-10-27 23:22:36 (UTC)
commitcbda16d4966c7483d20d1b6b5a64c8af367ea732 (patch) (side-by-side diff)
tree47099fd5b318c47eb1d8fff3d8a3eef6e34f6f23 /korganizer/komonthview.cpp
parentd6d384e50cfd511866958e58cdd3adeb35ed1c4e (diff)
downloadkdepimpi-cbda16d4966c7483d20d1b6b5a64c8af367ea732.zip
kdepimpi-cbda16d4966c7483d20d1b6b5a64c8af367ea732.tar.gz
kdepimpi-cbda16d4966c7483d20d1b6b5a64c8af367ea732.tar.bz2
us fix
Diffstat (limited to 'korganizer/komonthview.cpp') (more/less context) (show whitespace changes)
-rw-r--r--korganizer/komonthview.cpp14
1 files changed, 11 insertions, 3 deletions
diff --git a/korganizer/komonthview.cpp b/korganizer/komonthview.cpp
index 610aae6..85e9166 100644
--- a/korganizer/komonthview.cpp
+++ b/korganizer/komonthview.cpp
@@ -737,12 +737,20 @@ int MonthViewCell::insertEvent(Event *event)
}
text = time + event->summary();
- if ( useToolTips ) {
- mToolTipText += prefix + text;
+
+ int dur = 0;
if ( event->doesFloat() ) {
- mToolTipText += i18n(" (Duration: %1 days)" ).arg ( event->dtStart().daysTo(event->dtEnd())+1);
+ dur = event->dtStart().daysTo(event->dtEnd())+1;
}
+ if ( useToolTips ) {
+ mToolTipText += prefix + text;
+ if ( dur ) {
+ mToolTipText += i18n(" (Duration: %1 days)" ).arg ( dur );
+ }
+ }
+ if ( dur ) {
+ text += " ("+ QString::number( dur ) + i18n(" days" ) + ")";
}
} else {
if (event->doesFloat()) {