From ee9dd0bc823bf76f885a23a95cb85843c4d5c714 Mon Sep 17 00:00:00 2001 From: Shuo Wang Date: Mon, 17 Jul 2023 11:34:20 +0800 Subject: [PATCH] update to 5.15.9 Signed-off-by: Shuo Wang --- ...erPopup-if-it-s-removed-from-childre.patch | 12 +-- ...crash-when-changing-sizes-after-clea.patch | 4 +- ...not-showing-up-when-binding-to-stand.patch | 6 +- ...-t-grab-the-same-shortcut-multiple-t.patch | 49 ---------- ...tractButton-fix-crash-on-destruction.patch | 89 ------------------- ...11y-pressing-of-qquickabstractbutton.patch | 55 ++++++++++++ 0005-Fix-the-popup-position-of-a-Menu.patch | 45 ++++++++++ qt5-qtquickcontrols2.spec | 13 +-- sources | 2 +- 9 files changed, 120 insertions(+), 155 deletions(-) rename 0005-Fix-scroll-bars-not-showing-up-when-binding-to-stand.patch => 0003-Fix-scroll-bars-not-showing-up-when-binding-to-stand.patch (98%) delete mode 100644 0003-QQuickAction-don-t-grab-the-same-shortcut-multiple-t.patch delete mode 100644 0004-QQuickAbstractButton-fix-crash-on-destruction.patch create mode 100644 0004-implement-a11y-pressing-of-qquickabstractbutton.patch create mode 100644 0005-Fix-the-popup-position-of-a-Menu.patch diff --git a/0001-Unset-mouseGrabberPopup-if-it-s-removed-from-childre.patch b/0001-Unset-mouseGrabberPopup-if-it-s-removed-from-childre.patch index bbad62d..b6ef009 100644 --- a/0001-Unset-mouseGrabberPopup-if-it-s-removed-from-childre.patch +++ b/0001-Unset-mouseGrabberPopup-if-it-s-removed-from-childre.patch @@ -1,4 +1,4 @@ -From 77b25c91dfcc5b4320b25c30ad8955c41b7d2fdb Mon Sep 17 00:00:00 2001 +From 4fd68622be6c6b2b16f8d976b640b79d26dcc075 Mon Sep 17 00:00:00 2001 From: David Redondo Date: Mon, 19 Jul 2021 10:06:17 +0200 Subject: [PATCH 1/5] Unset mouseGrabberPopup if it's removed from children @@ -30,7 +30,7 @@ Reviewed-by: Mitch Curtis create mode 100644 tests/auto/qquickpopup/data/releaseAfterExitTransition.qml diff --git a/src/quicktemplates2/qquickoverlay.cpp b/src/quicktemplates2/qquickoverlay.cpp -index b8d417f29..c8cd142ae 100644 +index 91bd59184..0ce518f84 100644 --- a/src/quicktemplates2/qquickoverlay.cpp +++ b/src/quicktemplates2/qquickoverlay.cpp @@ -399,8 +399,11 @@ void QQuickOverlay::itemChange(ItemChange change, const ItemChangeData &data) @@ -131,10 +131,10 @@ index 000000000..9e4598b9f + } +} diff --git a/tests/auto/qquickpopup/tst_qquickpopup.cpp b/tests/auto/qquickpopup/tst_qquickpopup.cpp -index ede3640c2..f1840946b 100644 +index 54952d128..3d50e2dd4 100644 --- a/tests/auto/qquickpopup/tst_qquickpopup.cpp +++ b/tests/auto/qquickpopup/tst_qquickpopup.cpp -@@ -97,6 +97,7 @@ private slots: +@@ -100,6 +100,7 @@ private slots: void invisibleToolTipOpen(); void centerInOverlayWithinStackViewItem(); void destroyDuringExitTransition(); @@ -142,7 +142,7 @@ index ede3640c2..f1840946b 100644 }; void tst_QQuickPopup::initTestCase() -@@ -1459,6 +1460,34 @@ void tst_QQuickPopup::destroyDuringExitTransition() +@@ -1575,6 +1576,34 @@ void tst_QQuickPopup::destroyDuringExitTransition() QVERIFY(!button->isDown()); } @@ -178,5 +178,5 @@ index ede3640c2..f1840946b 100644 #include "tst_qquickpopup.moc" -- -2.37.3 +2.40.0 diff --git a/0002-Ensure-we-don-t-crash-when-changing-sizes-after-clea.patch b/0002-Ensure-we-don-t-crash-when-changing-sizes-after-clea.patch index d458652..1e09356 100644 --- a/0002-Ensure-we-don-t-crash-when-changing-sizes-after-clea.patch +++ b/0002-Ensure-we-don-t-crash-when-changing-sizes-after-clea.patch @@ -1,4 +1,4 @@ -From 4ec806a511090cd6298fa783d63a7a46f9174a21 Mon Sep 17 00:00:00 2001 +From 774cc9a0d8c177b4363b11b80f88296318967385 Mon Sep 17 00:00:00 2001 From: Aleix Pol Date: Tue, 4 Jan 2022 16:34:16 +0100 Subject: [PATCH 2/5] Ensure we don't crash when changing sizes after cleanup @@ -79,5 +79,5 @@ index e6db14eb5..6197d1547 100644 qreal maxHeight = 0; for (int i = 0; i < count; ++i) { -- -2.37.3 +2.40.0 diff --git a/0005-Fix-scroll-bars-not-showing-up-when-binding-to-stand.patch b/0003-Fix-scroll-bars-not-showing-up-when-binding-to-stand.patch similarity index 98% rename from 0005-Fix-scroll-bars-not-showing-up-when-binding-to-stand.patch rename to 0003-Fix-scroll-bars-not-showing-up-when-binding-to-stand.patch index 16b549d..44e9481 100644 --- a/0005-Fix-scroll-bars-not-showing-up-when-binding-to-stand.patch +++ b/0003-Fix-scroll-bars-not-showing-up-when-binding-to-stand.patch @@ -1,7 +1,7 @@ -From 9ff77702cc3649cbaf94046742d682d77cdea698 Mon Sep 17 00:00:00 2001 +From 7145c2589193b0ca0eafbb35085bc5cb5613b055 Mon Sep 17 00:00:00 2001 From: Mitch Curtis Date: Mon, 18 Jul 2022 15:21:49 +0800 -Subject: [PATCH 5/5] Fix scroll bars not showing up when binding to standalone +Subject: [PATCH 3/5] Fix scroll bars not showing up when binding to standalone contentItem 908aa77d16e00f2bccc0ddae0f8b61955c56a6a1 hid old scroll bars, but @@ -175,5 +175,5 @@ index 0e8b08352..cd4931184 100644 + } } -- -2.37.3 +2.40.0 diff --git a/0003-QQuickAction-don-t-grab-the-same-shortcut-multiple-t.patch b/0003-QQuickAction-don-t-grab-the-same-shortcut-multiple-t.patch deleted file mode 100644 index 64c2707..0000000 --- a/0003-QQuickAction-don-t-grab-the-same-shortcut-multiple-t.patch +++ /dev/null @@ -1,49 +0,0 @@ -From 034a6e6f046d6ce97395ecad1b31b6a920f980d4 Mon Sep 17 00:00:00 2001 -From: Oliver Eftevaag -Date: Wed, 19 Jan 2022 22:09:56 +0100 -Subject: [PATCH 3/5] QQuickAction: don't grab the same shortcut multiple times - -If the entry for the QQuickItem that the QQuickAction is set on has -already grabbed the shortcut, then m_shortcutId is no longer 0 and we -must not overwrite the value. Otherwise, the QQuickItem removing itself -from the action might not remove the correct entry from Qt's shortcut -map, leaving a dangling pointer behind. - -Multiple calls to QQuickActionPrivate::ShortcutEntry::grab are possible, -because we grab the shortcut whenever the shortcut changes, or when an -item representing the action becomes visible. - -The test case added reproduces this scenario by adding the action to a -menu item and then making the menu explicitly visible, resulting in two -calls to grab() which should be idempotent. - -Fixes: QTBUG-96551 -Fixes: QTBUG-96561 -Pick-to: 6.2 -Change-Id: I7d42a4f4c04f7d8759f2d0f24a133720f10e4c47 -Reviewed-by: Mitch Curtis -Reviewed-by: Jarkko Koivikko -Reviewed-by: Volker Hilsheimer - -(cherry picked from commit 45af5ef2f63704adc515e29260ad8c6aaf51f08e in -qtdeclarative) ---- - src/quicktemplates2/qquickaction.cpp | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/src/quicktemplates2/qquickaction.cpp b/src/quicktemplates2/qquickaction.cpp -index 2041e7741..8610cdfae 100644 ---- a/src/quicktemplates2/qquickaction.cpp -+++ b/src/quicktemplates2/qquickaction.cpp -@@ -145,7 +145,7 @@ int QQuickActionPrivate::ShortcutEntry::shortcutId() const - - void QQuickActionPrivate::ShortcutEntry::grab(const QKeySequence &shortcut, bool enabled) - { -- if (shortcut.isEmpty()) -+ if (shortcut.isEmpty() || m_shortcutId) - return; - - Qt::ShortcutContext context = Qt::WindowShortcut; // TODO --- -2.37.3 - diff --git a/0004-QQuickAbstractButton-fix-crash-on-destruction.patch b/0004-QQuickAbstractButton-fix-crash-on-destruction.patch deleted file mode 100644 index 344c3f5..0000000 --- a/0004-QQuickAbstractButton-fix-crash-on-destruction.patch +++ /dev/null @@ -1,89 +0,0 @@ -From 1bd1ceae8b8340f9d0e06b55a301c4642324d64a Mon Sep 17 00:00:00 2001 -From: Ulf Hermann -Date: Tue, 11 Jan 2022 12:42:47 +0100 -Subject: [PATCH 4/5] QQuickAbstractButton: fix crash on destruction - -If we listen for size changes we also need to remove the object listened -to when it's deleted. - -Pick-to: 5.15 6.2 6.3 -Fixes: QTBUG-99644 -Change-Id: I613855ebd986b1e67685088020b88d8b070659cf -Reviewed-by: Mitch Curtis -(cherry picked from commit 720ffaeb60d43123522066e1de3a69ad551644aa in -qtdeclarative) ---- - src/quicktemplates2/qquickabstractbutton.cpp | 11 +++++++++ - .../qquickabstractbutton_p_p.h | 1 + - tests/auto/controls/data/tst_switch.qml | 23 +++++++++++++++++++ - 3 files changed, 35 insertions(+) - -diff --git a/src/quicktemplates2/qquickabstractbutton.cpp b/src/quicktemplates2/qquickabstractbutton.cpp -index 950e4e099..1df0c706d 100644 ---- a/src/quicktemplates2/qquickabstractbutton.cpp -+++ b/src/quicktemplates2/qquickabstractbutton.cpp -@@ -387,6 +387,17 @@ void QQuickAbstractButtonPrivate::itemImplicitHeightChanged(QQuickItem *item) - emit q->implicitIndicatorHeightChanged(); - } - -+void QQuickAbstractButtonPrivate::itemDestroyed(QQuickItem *item) -+{ -+ Q_Q(QQuickAbstractButton); -+ QQuickControlPrivate::itemDestroyed(item); -+ if (item == indicator) { -+ indicator = nullptr; -+ emit q->implicitIndicatorWidthChanged(); -+ emit q->implicitIndicatorHeightChanged(); -+ } -+} -+ - QQuickAbstractButton *QQuickAbstractButtonPrivate::findCheckedButton() const - { - Q_Q(const QQuickAbstractButton); -diff --git a/src/quicktemplates2/qquickabstractbutton_p_p.h b/src/quicktemplates2/qquickabstractbutton_p_p.h -index 9291c1a87..b729720f2 100644 ---- a/src/quicktemplates2/qquickabstractbutton_p_p.h -+++ b/src/quicktemplates2/qquickabstractbutton_p_p.h -@@ -109,6 +109,7 @@ public: - - void itemImplicitWidthChanged(QQuickItem *item) override; - void itemImplicitHeightChanged(QQuickItem *item) override; -+ void itemDestroyed(QQuickItem *item) override; - - // copied from qabstractbutton.cpp - static const int AUTO_REPEAT_DELAY = 300; -diff --git a/tests/auto/controls/data/tst_switch.qml b/tests/auto/controls/data/tst_switch.qml -index b3fab41ca..10b6baa02 100644 ---- a/tests/auto/controls/data/tst_switch.qml -+++ b/tests/auto/controls/data/tst_switch.qml -@@ -608,4 +608,27 @@ TestCase { - mouseClick(control.indicator) - verify(control.activeFocus) - } -+ -+ Component { -+ id: deletionOrder1 -+ Item { -+ Image { id: innerImage } -+ Switch { indicator: innerImage } -+ } -+ } -+ -+ Component { -+ id: deletionOrder2 -+ Item { -+ Switch { indicator: innerImage } -+ Image { id: innerImage } -+ } -+ } -+ -+ function test_deletionOrder() { -+ var control1 = createTemporaryObject(deletionOrder1, testCase) -+ verify(control1) -+ var control2 = createTemporaryObject(deletionOrder2, testCase) -+ verify(control2) -+ } - } --- -2.37.3 - diff --git a/0004-implement-a11y-pressing-of-qquickabstractbutton.patch b/0004-implement-a11y-pressing-of-qquickabstractbutton.patch new file mode 100644 index 0000000..6acab55 --- /dev/null +++ b/0004-implement-a11y-pressing-of-qquickabstractbutton.patch @@ -0,0 +1,55 @@ +From 29c60b84e92c83c28211bc349eb00e6c93eeed80 Mon Sep 17 00:00:00 2001 +From: Harald Sitter +Date: Wed, 2 Nov 2022 12:39:11 +0100 +Subject: [PATCH 4/5] implement a11y pressing of qquickabstractbutton +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +this adds a pressAction default implementation that simply calls trigger +(which in turn either triggers the action or emits a click), allowing +accessibility tools to issue a button press via a11y api. + +Change-Id: I75b4fb8680835093b1135fdbf4329aaa85dc3243 +Reviewed-by: Arjen Hiemstra +Reviewed-by: Aleix Pol Gonzalez +Reviewed-by: Jan Arve Sæther +(cherry picked from commit 705659eaaf47af72eeb5f5c742e18a5c665a76eb in +qtdeclarative) +--- + src/quicktemplates2/qquickabstractbutton.cpp | 6 ++++++ + src/quicktemplates2/qquickabstractbutton_p.h | 1 + + 2 files changed, 7 insertions(+) + +diff --git a/src/quicktemplates2/qquickabstractbutton.cpp b/src/quicktemplates2/qquickabstractbutton.cpp +index 20cf59c1a..43af47a94 100644 +--- a/src/quicktemplates2/qquickabstractbutton.cpp ++++ b/src/quicktemplates2/qquickabstractbutton.cpp +@@ -1201,6 +1201,12 @@ QAccessible::Role QQuickAbstractButton::accessibleRole() const + } + return QAccessible::Button; + } ++ ++void QQuickAbstractButton::accessiblePressAction() ++{ ++ Q_D(QQuickAbstractButton); ++ d->trigger(); ++} + #endif + + QT_END_NAMESPACE +diff --git a/src/quicktemplates2/qquickabstractbutton_p.h b/src/quicktemplates2/qquickabstractbutton_p.h +index 0fa48980e..ab66220d0 100644 +--- a/src/quicktemplates2/qquickabstractbutton_p.h ++++ b/src/quicktemplates2/qquickabstractbutton_p.h +@@ -209,6 +209,7 @@ protected: + #if QT_CONFIG(accessibility) + void accessibilityActiveChanged(bool active) override; + QAccessible::Role accessibleRole() const override; ++ Q_INVOKABLE void accessiblePressAction(); + #endif + + private: +-- +2.40.0 + diff --git a/0005-Fix-the-popup-position-of-a-Menu.patch b/0005-Fix-the-popup-position-of-a-Menu.patch new file mode 100644 index 0000000..eb5ee84 --- /dev/null +++ b/0005-Fix-the-popup-position-of-a-Menu.patch @@ -0,0 +1,45 @@ +From 86a84eaa74c4071e5750f23b6e9911762880d391 Mon Sep 17 00:00:00 2001 +From: Inho Lee +Date: Mon, 22 Aug 2022 21:05:00 +0800 +Subject: [PATCH 5/5] Fix the popup position of a Menu +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +QPA code should operate in native coord. +Treat QWidgetPlatformMenu::showPopup's input as native coord. + +Fixes: QTBUG-94619 +Fixes: QTBUG-94783 +Change-Id: Iaa030c96d84e4a588e625fe191e4324f70be961f +Reviewed-by: Morten Johan Sørvig +(cherry picked from commit f8cf17166c9af147f0b8fea72f5b4a8a6098a5d7 in +qtdeclarative) +--- + src/imports/platform/widgets/qwidgetplatformmenu.cpp | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/src/imports/platform/widgets/qwidgetplatformmenu.cpp b/src/imports/platform/widgets/qwidgetplatformmenu.cpp +index e5fe734f7..e36922775 100644 +--- a/src/imports/platform/widgets/qwidgetplatformmenu.cpp ++++ b/src/imports/platform/widgets/qwidgetplatformmenu.cpp +@@ -38,6 +38,7 @@ + #include "qwidgetplatformmenuitem_p.h" + + #include ++#include + #include + #include + +@@ -145,7 +146,7 @@ void QWidgetPlatformMenu::showPopup(const QWindow *window, const QRect &targetRe + + QPoint targetPos = targetRect.bottomLeft(); + if (window) +- targetPos = window->mapToGlobal(targetPos); ++ targetPos = window->mapToGlobal(QHighDpi::fromNativeLocalPosition(targetPos, window)); + + const QWidgetPlatformMenuItem *widgetItem = qobject_cast(item); + m_menu->popup(targetPos, widgetItem ? widgetItem->action() : nullptr); +-- +2.40.0 + diff --git a/qt5-qtquickcontrols2.spec b/qt5-qtquickcontrols2.spec index c3008fc..b79b7a0 100644 --- a/qt5-qtquickcontrols2.spec +++ b/qt5-qtquickcontrols2.spec @@ -4,17 +4,17 @@ Summary: Qt5 - module with set of QtQuick controls for embedded Name: qt5-%{qt_module} -Version: 5.15.7 -Release: 3%{?dist} +Version: 5.15.9 +Release: 1%{?dist} License: GPLv2+ or LGPLv3 and GFDL Url: http://www.qt.io Source0: https://download.qt.io/official_releases/qt/%{majmin}/%{version}/submodules/%{qt_module}-everywhere-opensource-src-%{version}.tar.xz Patch3001: 0001-Unset-mouseGrabberPopup-if-it-s-removed-from-childre.patch Patch3002: 0002-Ensure-we-don-t-crash-when-changing-sizes-after-clea.patch -Patch3003: 0003-QQuickAction-don-t-grab-the-same-shortcut-multiple-t.patch -Patch3004: 0004-QQuickAbstractButton-fix-crash-on-destruction.patch -Patch3005: 0005-Fix-scroll-bars-not-showing-up-when-binding-to-stand.patch +Patch3003: 0003-Fix-scroll-bars-not-showing-up-when-binding-to-stand.patch +Patch3004: 0004-implement-a11y-pressing-of-qquickabstractbutton.patch +Patch3005: 0005-Fix-the-popup-position-of-a-Menu.patch BuildRequires: make BuildRequires: qt5-qtbase-devel >= %{version} @@ -82,6 +82,9 @@ rm -f %{buildroot}%{_qt5_libdir}/libQt5*.la %{_qt5_examplesdir}/quickcontrols2/ %changelog +* Mon Jul 17 2023 Shuo Wang - 5.15.9-1 +- update to 5.15.9 + * Fri Apr 28 2023 OpenCloudOS Release Engineering - 5.15.7-3 - Rebuilt for OpenCloudOS Stream 23.05 diff --git a/sources b/sources index 964dedd..bab46c9 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (qtquickcontrols2-everywhere-opensource-src-5.15.7.tar.xz) = f49e330593b23ab9e84874a7cee1583df9355dd68d7c25e57fba080997b860b86f9003190e5d9a5b393efcb143fd20866daf2c8088a769e3094d6cf9607febd5 +SHA512 (qtquickcontrols2-everywhere-opensource-src-5.15.9.tar.xz) = f77a59cb6704438bc7b81f816454dad56bebdf4ce7f015c21a05b09f0c508525750a0cf232da8d7428464aa68de9a2bcbd000906fa781aff1e60e8ee5d70802e -- Gitee