author | ar <ar> | 2004-02-07 23:52:31 (UTC) |
---|---|---|
committer | ar <ar> | 2004-02-07 23:52:31 (UTC) |
commit | 6582895befc98131430710191238a93b9dde161c (patch) (unidiff) | |
tree | d050483742d0e102e08138bcdd8f170a9558b12d /core/pim/todo/mainwindow.cpp | |
parent | 3f261fa6eac46b8d0d4ac8b8bb95b385435004da (diff) | |
download | opie-6582895befc98131430710191238a93b9dde161c.zip opie-6582895befc98131430710191238a93b9dde161c.tar.gz opie-6582895befc98131430710191238a93b9dde161c.tar.bz2 |
QPEApplication::showDialog() and QPEAPplication::execDialog() for better big screen handling
Diffstat (limited to 'core/pim/todo/mainwindow.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | core/pim/todo/mainwindow.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/core/pim/todo/mainwindow.cpp b/core/pim/todo/mainwindow.cpp index d06a405..fc189bd 100644 --- a/core/pim/todo/mainwindow.cpp +++ b/core/pim/todo/mainwindow.cpp | |||
@@ -1019,26 +1019,25 @@ void MainWindow::doAlarm( const QDateTime& dt, int uid ) { | |||
1019 | QDialog dlg(this, 0, TRUE ); | 1019 | QDialog dlg(this, 0, TRUE ); |
1020 | QVBoxLayout* lay = new QVBoxLayout( &dlg ); | 1020 | QVBoxLayout* lay = new QVBoxLayout( &dlg ); |
1021 | QTextView* view = new QTextView( &dlg ); | 1021 | QTextView* view = new QTextView( &dlg ); |
1022 | lay->addWidget( view ); | 1022 | lay->addWidget( view ); |
1023 | QPushButton* btnOk = new QPushButton( tr("Ok"), &dlg ); | 1023 | QPushButton* btnOk = new QPushButton( tr("Ok"), &dlg ); |
1024 | connect( btnOk, SIGNAL(clicked() ), &dlg, SLOT(accept() ) ); | 1024 | connect( btnOk, SIGNAL(clicked() ), &dlg, SLOT(accept() ) ); |
1025 | lay->addWidget( btnOk ); | 1025 | lay->addWidget( btnOk ); |
1026 | 1026 | ||
1027 | QString text = tr("<h1>Alarm at %1</h1><br>").arg( TimeString::dateString( dt ) ); | 1027 | QString text = tr("<h1>Alarm at %1</h1><br>").arg( TimeString::dateString( dt ) ); |
1028 | text += todo.toRichText(); | 1028 | text += todo.toRichText(); |
1029 | view->setText( text ); | 1029 | view->setText( text ); |
1030 | 1030 | ||
1031 | dlg.showMaximized(); | 1031 | bool needToStay = QPEApplication::execDialog( &dlg ); |
1032 | bool needToStay = dlg.exec(); | ||
1033 | 1032 | ||
1034 | if (loud) | 1033 | if (loud) |
1035 | killAlarm(); | 1034 | killAlarm(); |
1036 | 1035 | ||
1037 | if (needToStay) { | 1036 | if (needToStay) { |
1038 | // showMaximized(); | 1037 | // showMaximized(); |
1039 | // raise(); | 1038 | // raise(); |
1040 | QPEApplication::setKeepRunning(); | 1039 | QPEApplication::setKeepRunning(); |
1041 | // setActiveWindow(); | 1040 | // setActiveWindow(); |
1042 | } | 1041 | } |
1043 | 1042 | ||
1044 | } | 1043 | } |