author | zautrix <zautrix> | 2005-04-03 04:33:19 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2005-04-03 04:33:19 (UTC) |
commit | f6c8249db564c1276d4c7ed5ad88c6fbac361b8d (patch) (side-by-side diff) | |
tree | 8e5b6e2d6f9a7bc00326f7c0115bf2af53ae9ce8 /korganizer/calendarview.cpp | |
parent | 40e5edc1ab153144f0e824ad2d3a0ab37357e408 (diff) | |
download | kdepimpi-f6c8249db564c1276d4c7ed5ad88c6fbac361b8d.zip kdepimpi-f6c8249db564c1276d4c7ed5ad88c6fbac361b8d.tar.gz kdepimpi-f6c8249db564c1276d4c7ed5ad88c6fbac361b8d.tar.bz2 |
fixes
-rw-r--r-- | korganizer/calendarview.cpp | 19 |
1 files changed, 17 insertions, 2 deletions
diff --git a/korganizer/calendarview.cpp b/korganizer/calendarview.cpp index beb19d9..76cce26 100644 --- a/korganizer/calendarview.cpp +++ b/korganizer/calendarview.cpp @@ -527,12 +527,17 @@ void CalendarView::suspendAlarm() computeAlarm(mSuspendAlarmNotification ); } void CalendarView::startAlarm( QString mess , QString filename) { + + topLevelWidget()->showNormal(); + topLevelWidget()->setActiveWindow(); + topLevelWidget()->raise(); + mAlarmDialog->eventNotification( mess, KOPrefs::instance()->mAlarmPlayBeeps, filename, true,KOPrefs::instance()->mAlarmBeepInterval ,KOPrefs::instance()->mAlarmSuspendCount ); QTimer::singleShot( 3000, this, SLOT( checkNextTimerAlarm() ) ); } void CalendarView::checkNextTimerAlarm() @@ -4091,27 +4096,37 @@ void CalendarView::showNextAlarms() int min = secs /60; int hours = min /60; min = min % 60; int days = hours /24; hours = hours % 24; - message = i18n("The next alarm is in:\n"); + //message = i18n("The next alarm is in:\n"); if ( days > 1 ) message += i18n("%1 days\n").arg( days ); else if ( days == 1 ) message += i18n("1 day\n"); if ( hours > 1 ) message += i18n("%1 hours\n").arg( hours ); else if ( hours == 1 ) message += i18n("1 hour\n"); if ( min > 1 ) message += i18n("%1 minutes\n").arg( min ); else if ( min == 1 ) message += i18n("1 minute\n"); - + if ( message.isEmpty() ) + message = i18n("The next alarm is in\nless than one minute!"); + else + message = i18n("The next alarm is in:\n") + message; message += i18n("\n(%1)\n\n%2\n(%3)\n").arg( KGlobal::locale()->formatDateTime(nextA , false)).arg(sum ).arg( KGlobal::locale()->formatDateTime(nextAl , false)) ; } else { message = i18n("There is no next alarm."); } +#ifdef DESKTOP_VERSION + if ( ! KOPrefs::instance()->mUseInternalAlarmNotification ) { + message += i18n("\nThe internal alarm notification is disabled!\n"); + message += i18n("Enable it in the settings menu, TAB alarm."); + } + +#endif KMessageBox::information( this, message); } |