diff options
author | Sami Merila <sami.merila@nokia.com> | 2010-06-30 07:30:47 (GMT) |
---|---|---|
committer | Sami Merila <sami.merila@nokia.com> | 2010-06-30 07:30:47 (GMT) |
commit | 30ef2af599f85fef56b975f45fd4edfe817a449a (patch) | |
tree | eab6c64a1a8e9edb8cdfb430df293015c8d595d6 /src/gui/dialogs | |
parent | 587b0fed9bd17a378eb0212c95074df965549ef2 (diff) | |
download | Qt-30ef2af599f85fef56b975f45fd4edfe817a449a.zip Qt-30ef2af599f85fef56b975f45fd4edfe817a449a.tar.gz Qt-30ef2af599f85fef56b975f45fd4edfe817a449a.tar.bz2 |
QFileDialog broken in landscape in N8
The screen estate runs out for nHD landscape. Due to this, all
"system" dialogs (file, color, font dialogs and wizards) in Symbian
are now shown in fullscreen mode, instead of being just maximized.
Task-number: QTBUG-11668
Reviewed-by: Miikka Heikkinen
Diffstat (limited to 'src/gui/dialogs')
-rw-r--r-- | src/gui/dialogs/qdialog.cpp | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/src/gui/dialogs/qdialog.cpp b/src/gui/dialogs/qdialog.cpp index a6bd78a..c2184f2 100644 --- a/src/gui/dialogs/qdialog.cpp +++ b/src/gui/dialogs/qdialog.cpp @@ -527,14 +527,19 @@ int QDialog::exec() #endif //QT_NO_MENUBAR #endif //Q_WS_WINCE_WM + bool showSystemDialogFullScreen = false; #ifdef Q_OS_SYMBIAN if (qobject_cast<QFileDialog *>(this) || qobject_cast<QFontDialog *>(this) || - qobject_cast<QColorDialog *>(this) || qobject_cast<QWizard *>(this)) - showMaximized(); - else + qobject_cast<QColorDialog *>(this) || qobject_cast<QWizard *>(this)) { + showSystemDialogFullScreen = true; + } #endif // Q_OS_SYMBIAN - show(); + if (showSystemDialogFullScreen) { + setWindowFlags(windowFlags() | Qt::WindowSoftkeysVisibleHint); + setWindowState(Qt::WindowFullScreen); + } + show(); #ifdef Q_WS_MAC d->mac_nativeDialogModalHelp(); @@ -892,8 +897,6 @@ void QDialog::adjustPosition(QWidget* w) bool QDialog::s60AdjustedPosition() { QPoint p; - const QSize mainAreaSize = QApplication::desktop()->availableGeometry(QCursor::pos()).size(); - const int statusPaneHeight = (S60->screenHeightInPixels - mainAreaSize.height())>>1; const bool doS60Positioning = !(isFullScreen()||isMaximized()); if (doS60Positioning) { // naive way to deduce screen orientation |