From 6b23a90876ac8c92ec8fa4901618104ebf7865f5ae631f16fa392fff0cb7ff35 Mon Sep 17 00:00:00 2001 From: Stephan Kulow Date: Fri, 30 Oct 2015 20:51:03 +0000 Subject: [PATCH] Accepting request 341376 from KDE:Qt5 OBS-URL: https://build.opensuse.org/request/show/341376 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/libqt5-qtbase?expand=0&rev=49 --- libqt5-qtbase.changes | 6 ++++ libqt5-qtbase.spec | 2 ++ ...WA_OutsideWSRange_for_native_widgets.patch | 32 +++++++++++++++++++ 3 files changed, 40 insertions(+) create mode 100644 qtwidgets_do_not-hide_show_via_WA_OutsideWSRange_for_native_widgets.patch diff --git a/libqt5-qtbase.changes b/libqt5-qtbase.changes index 696b4bb..0dfa057 100644 --- a/libqt5-qtbase.changes +++ b/libqt5-qtbase.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Wed Oct 28 19:41:36 UTC 2015 - hrvoje.senjan@gmail.com + +- Added qtwidgets_do_not-hide_show_via_WA_OutsideWSRange_for_native_widgets.patch + (qtbug#48321) + ------------------------------------------------------------------- Fri Oct 16 20:22:25 UTC 2015 - hrvoje.senjan@gmail.com diff --git a/libqt5-qtbase.spec b/libqt5-qtbase.spec index 6281ab9..6915277 100644 --- a/libqt5-qtbase.spec +++ b/libqt5-qtbase.spec @@ -62,6 +62,7 @@ Patch3003: move-the-official-Qt-version-from-qglobal-to-qmake-conf.patch Patch3004: Add-an-automatic-use-of-the-ELF-versioned-QtCore-symbol.patch Patch3005: xcb-fix-yet-another-crash-when-screens-are-disconnected.patch Patch3006: xcb-dont-crash-in-mapToNativemapFromNative-if-the-screen-is-null.patch +Patch3007: qtwidgets_do_not-hide_show_via_WA_OutsideWSRange_for_native_widgets.patch BuildRequires: alsa-devel BuildRequires: cups-devel BuildRequires: gcc-c++ @@ -153,6 +154,7 @@ handling. %patch3004 -p1 %patch3005 -p1 %patch3006 -p1 +%patch3007 -p1 # be sure not to use them rm -r src/3rdparty/{libjpeg,freetype,libpng,zlib} diff --git a/qtwidgets_do_not-hide_show_via_WA_OutsideWSRange_for_native_widgets.patch b/qtwidgets_do_not-hide_show_via_WA_OutsideWSRange_for_native_widgets.patch new file mode 100644 index 0000000..f03806d --- /dev/null +++ b/qtwidgets_do_not-hide_show_via_WA_OutsideWSRange_for_native_widgets.patch @@ -0,0 +1,32 @@ +From acb4f5cfb5efa053dd2d5dcd6490d610bb1f8c0e Mon Sep 17 00:00:00 2001 +From: Ulf Hermann +Date: Tue, 27 Oct 2015 15:25:42 +0100 +Subject: [PATCH] QtWidgets: Do hide/show via WA_OutsideWSRange for native + widgets + +If a native widget has a width or height of 0 we don't have to +invalidate its backing store as that is done by the window +system. Certain applications rely on ... interesting ... behavior +of certain window systems in this case. + +Task-number: QTBUG-48321 +Change-Id: I78ef29975181ee22429c9bd4b11d96d9e68b7a9c +--- + src/widgets/kernel/qwidget.cpp | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/widgets/kernel/qwidget.cpp b/src/widgets/kernel/qwidget.cpp +index 7734715..4286130 100644 +--- a/src/widgets/kernel/qwidget.cpp ++++ b/src/widgets/kernel/qwidget.cpp +@@ -7169,7 +7169,7 @@ void QWidgetPrivate::setGeometry_sys(int x, int y, int w, int h, bool isMove) + + bool needsShow = false; + +- if (q->isWindow()) { ++ if (q->isWindow() || q->windowHandle()) { + if (!(data.window_state & Qt::WindowFullScreen) && (w == 0 || h == 0)) { + q->setAttribute(Qt::WA_OutsideWSRange, true); + if (q->isVisible() && q->testAttribute(Qt::WA_Mapped)) +-- +2.1.4