From c5de1fcc13b32e7c1f893dc3f8a1385b8698ebaf Mon Sep 17 00:00:00 2001 From: sandman Date: Sun, 22 Dec 2002 19:02:29 +0000 Subject: correct implementation for QCop "nextView()": - if we are not active, raise the window - if we are active, switch to the next view (this is needed for the new appskey framework) --- diff --git a/core/pim/datebook/datebook.cpp b/core/pim/datebook/datebook.cpp index c0a744a..7dcf156 100644 --- a/core/pim/datebook/datebook.cpp +++ b/core/pim/datebook/datebook.cpp @@ -675,18 +675,23 @@ void DateBook::appMessage(const QCString& msg, const QByteArray& data) } } } else if ( msg == "nextView()" ) { - QWidget* cur = views->visibleWidget(); - if ( cur ) { - if ( cur == dayView ) - viewWeek(); - else if ( cur == weekView ) - viewWeekLst(); - else if ( cur == weekLstView ) - viewMonth(); - else if ( cur == monthView ) - viewDay(); + if ( !qApp-> activeWindow ( )) { needShow = TRUE; } + else { + QWidget* cur = views->visibleWidget(); + if ( cur ) { + if ( cur == dayView ) + viewWeek(); + else if ( cur == weekView ) + viewWeekLst(); + else if ( cur == weekLstView ) + viewMonth(); + else if ( cur == monthView ) + viewDay(); + needShow = TRUE; + } + } } if ( needShow ) { #if defined(Q_WS_QWS) || defined(_WS_QWS_) -- cgit v0.9.0.2