From 6582895befc98131430710191238a93b9dde161c Mon Sep 17 00:00:00 2001 From: ar Date: Sat, 07 Feb 2004 23:52:31 +0000 Subject: QPEApplication::showDialog() and QPEAPplication::execDialog() for better big screen handling --- (limited to 'core/pim/datebook') diff --git a/core/pim/datebook/datebook.cpp b/core/pim/datebook/datebook.cpp index 44f1515..706cc08 100644 --- a/core/pim/datebook/datebook.cpp +++ b/core/pim/datebook/datebook.cpp @@ -265,12 +265,7 @@ void DateBook::slotSettings() } frmSettings.comboCategory->setCategories(defaultCategories,"Calendar", tr("Calendar")); -#if defined (Q_WS_QWS) || defined(_WS_QWS_) - frmSettings.showMaximized(); -#endif - - if ( frmSettings.exec() ) { - + if ( QPEApplication::execDialog( &frmSettings ) ) { aPreset = frmSettings.alarmPreset(); presetTime = frmSettings.presetTime(); startTime = frmSettings.startTime(); @@ -437,10 +432,7 @@ void DateBook::duplicateEvent( const Event &e ) entry->timezone->setEnabled( FALSE ); sv->addChild( entry ); -#if defined(Q_WS_QWS) || defined(_WS_QWS_) - editDlg.showMaximized(); -#endif - while (editDlg.exec() ) { + while ( QPEApplication::execDialog( &editDlg ) ) { Event newEv = entry->event(); QString error = checkEvent(newEv); if (!error.isNull()) { @@ -486,10 +478,7 @@ void DateBook::editEvent( const Event &e ) entry->timezone->setEnabled( FALSE ); sv->addChild( entry ); -#if defined(Q_WS_QWS) || defined(_WS_QWS_) - editDlg.showMaximized(); -#endif - while (editDlg.exec() ) { + while ( QPEApplication::execDialog( &editDlg ) ) { Event newEv = entry->event(); if(newEv.description().isEmpty() && newEv.notes().isEmpty() ) break; @@ -707,10 +696,7 @@ void DateBook::appMessage(const QCString& msg, const QByteArray& data) connect( cmdOk, SIGNAL(clicked()), &dlg, SLOT(accept()) ); vb->addWidget( cmdOk ); -#if defined(Q_WS_QWS) || defined(_WS_QWS_) - dlg.showMaximized(); -#endif - needShow = dlg.exec(); + needShow = QPEApplication::execDialog( &dlg ); if ( bSound ) killTimer( stopTimer ); @@ -902,10 +888,7 @@ void DateBook::slotNewEntry(const QDateTime &start, const QDateTime &end, const e = new DateEntry( onMonday, ev, ampm, &newDlg ); e->setAlarmEnabled( aPreset, presetTime, Event::Loud ); sv->addChild( e ); -#if defined(Q_WS_QWS) || defined(_WS_QWS_) - newDlg.showMaximized(); -#endif - while (newDlg.exec()) { + while ( QPEApplication::execDialog( &newDlg ) ) { ev = e->event(); ev.assignUid(); QString error = checkEvent( ev ); diff --git a/core/pim/datebook/dateentryimpl.cpp b/core/pim/datebook/dateentryimpl.cpp index d9e5225..856837c 100644 --- a/core/pim/datebook/dateentryimpl.cpp +++ b/core/pim/datebook/dateentryimpl.cpp @@ -249,10 +249,7 @@ void DateEntry::slotEditNote() { NoteEntry noteDlg(s+comboDescription->currentText(), noteStr, this,0,TRUE); -#if defined(Q_WS_QWS) || defined(_WS_QWS_) - noteDlg.showMaximized(); -#endif - if (noteDlg.exec() ) { + if ( QPEApplication::execDialog( ¬eDlg ) ) { noteStr=noteDlg.note->text(); } @@ -395,10 +392,7 @@ void DateEntry::slotRepeat() else e = new RepeatEntry( startWeekOnMonday, startDate, this ); -#if defined(Q_WS_QWS) || defined(_WS_QWS_) - e->showMaximized(); -#endif - if ( e->exec() ) { + if ( QPEApplication::execDialog( e ) ) { rp = e->repeatPattern(); setRepeatLabel(); } -- cgit v0.9.0.2