From 0b19ee5ecabfc516256f0a6db0f2e7bc37e703a0 Mon Sep 17 00:00:00 2001 From: Sami Merila Date: Tue, 23 Aug 2011 14:55:46 +0300 Subject: In landscape mode QComboboBox popup can not be showed completely ComboBox popups have regressed in 4.7.4 lately. Combobox popup is shown as smallish square rectangle in landscape orientation. As a fix, let the width of the popup match the height of the screen (native dialogs most of the time have width matching the height of the screen). Task-number: QTBUG-20932 Reviewed-by: Miikka Heikkinen --- src/gui/widgets/qcombobox.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gui/widgets/qcombobox.cpp b/src/gui/widgets/qcombobox.cpp index f4a627b..8a69bdf 100644 --- a/src/gui/widgets/qcombobox.cpp +++ b/src/gui/widgets/qcombobox.cpp @@ -2473,7 +2473,7 @@ void QComboBox::showPopup() } else { TRect staConTopRect = TRect(); AknLayoutUtils::LayoutMetricsRect(AknLayoutUtils::EStaconTop, staConTopRect); - listRect.setWidth(listRect.height()); + listRect.setWidth(screen.height()); //by default popup is centered on screen in landscape listRect.moveCenter(screen.center()); if (staConTopRect.IsEmpty()) { -- cgit v0.12