restore fix for QTBUG-45753/kde-345544 lost in 5.4.2 rebase
This commit is contained in:
parent
5ca7568b94
commit
4741dae1b2
64
Avoid-calling-potentially-pure-virtual-method.patch
Normal file
64
Avoid-calling-potentially-pure-virtual-method.patch
Normal file
@ -0,0 +1,64 @@
|
||||
From 0d31aa1617c96ed3e3624d77332ea6f13aba1492 Mon Sep 17 00:00:00 2001
|
||||
From: David Edmundson <davidedmundson@kde.org>
|
||||
Date: Thu, 23 Apr 2015 15:01:24 +0200
|
||||
Subject: [PATCH 67/68] Avoid calling potentially pure virtual method
|
||||
|
||||
In Qt 5.4 screenChanged is called indirectly from the destructor of
|
||||
QPlatformScreen. By comparing new values against the oldScreen we call
|
||||
call virtual methods of QPlatformScreen from it's own destructor which
|
||||
results in a crash.
|
||||
|
||||
This patch simply emits change signals whenever a screen change regardless
|
||||
of whether the value differs from the previous screen. Arguably less
|
||||
efficient, but better than crashing.
|
||||
|
||||
This fix is not needed in Qt 5.5 where the QPA architecture has changed.
|
||||
|
||||
Task-number: QTBUG-45753
|
||||
Change-Id: Ic155906928855a377add9b21bff9e72b31f4667e
|
||||
Reviewed-by: Alan Alpert <aalpert@blackberry.com>
|
||||
---
|
||||
src/quick/items/qquickscreen.cpp | 27 +++++++++------------------
|
||||
1 file changed, 9 insertions(+), 18 deletions(-)
|
||||
|
||||
diff --git a/src/quick/items/qquickscreen.cpp b/src/quick/items/qquickscreen.cpp
|
||||
index c4d1407..0900adb 100644
|
||||
--- a/src/quick/items/qquickscreen.cpp
|
||||
+++ b/src/quick/items/qquickscreen.cpp
|
||||
@@ -347,24 +347,15 @@ void QQuickScreenAttached::screenChanged(QScreen *screen)
|
||||
emit orientationUpdateMaskChanged();
|
||||
}
|
||||
|
||||
- if (!oldScreen || screen->size() != oldScreen->size()) {
|
||||
- emit widthChanged();
|
||||
- emit heightChanged();
|
||||
- }
|
||||
- if (!oldScreen || screen->name() != oldScreen->name())
|
||||
- emit nameChanged();
|
||||
- if (!oldScreen || screen->orientation() != oldScreen->orientation())
|
||||
- emit orientationChanged();
|
||||
- if (!oldScreen || screen->primaryOrientation() != oldScreen->primaryOrientation())
|
||||
- emit primaryOrientationChanged();
|
||||
- if (!oldScreen || screen->availableVirtualGeometry() != oldScreen->availableVirtualGeometry())
|
||||
- emit desktopGeometryChanged();
|
||||
- if (!oldScreen || screen->logicalDotsPerInch() != oldScreen->logicalDotsPerInch())
|
||||
- emit logicalPixelDensityChanged();
|
||||
- if (!oldScreen || screen->physicalDotsPerInch() != oldScreen->physicalDotsPerInch())
|
||||
- emit pixelDensityChanged();
|
||||
- if (!oldScreen || screen->devicePixelRatio() != oldScreen->devicePixelRatio())
|
||||
- emit devicePixelRatioChanged();
|
||||
+ emit widthChanged();
|
||||
+ emit heightChanged();
|
||||
+ emit nameChanged();
|
||||
+ emit orientationChanged();
|
||||
+ emit primaryOrientationChanged();
|
||||
+ emit desktopGeometryChanged();
|
||||
+ emit logicalPixelDensityChanged();
|
||||
+ emit pixelDensityChanged();
|
||||
+ emit devicePixelRatioChanged();
|
||||
|
||||
connect(screen, SIGNAL(geometryChanged(QRect)),
|
||||
this, SIGNAL(widthChanged()));
|
||||
--
|
||||
2.3.7
|
||||
|
@ -13,7 +13,7 @@
|
||||
Summary: Qt5 - QtDeclarative component
|
||||
Name: qt5-%{qt_module}
|
||||
Version: 5.4.2
|
||||
Release: 1%{?dist}
|
||||
Release: 2%{?dist}
|
||||
|
||||
# See LICENSE.GPL LICENSE.LGPL LGPL_EXCEPTION.txt, for details
|
||||
License: LGPLv2 with exceptions or GPLv3 with exceptions
|
||||
@ -24,12 +24,13 @@ Source0: http://download.qt-project.org/development_releases/qt/5.4/%{version}-%
|
||||
Source0: http://download.qt-project.org/official_releases/qt/5.4/%{version}/submodules/%{qt_module}-opensource-src-%{version}.tar.xz
|
||||
%endif
|
||||
|
||||
## upstream patches
|
||||
|
||||
# support no_sse2 CONFIG (fedora i686 builds cannot assume -march=pentium4 -msse2 -mfpmath=sse flags, or the JIT that needs them)
|
||||
# https://codereview.qt-project.org/#change,73710
|
||||
Patch1: qtdeclarative-opensource-src-5.4.1-no_sse2.patch
|
||||
|
||||
# QTBUG-45753/kde-345544, can drop when 5.5.0 lands
|
||||
Patch2: Avoid-calling-potentially-pure-virtual-method.patch
|
||||
|
||||
Obsoletes: qt5-qtjsbackend < 5.2.0
|
||||
|
||||
BuildRequires: qt5-qtbase-devel >= %{version}
|
||||
@ -79,11 +80,9 @@ Requires: %{name}%{?_isa} = %{version}-%{release}
|
||||
%prep
|
||||
%autosetup -p1 -n %{qt_module}-opensource-src-%{version}%{?pre:-%{pre}}
|
||||
|
||||
#patch1 -p1 -b .no_sse2
|
||||
|
||||
|
||||
%build
|
||||
mkdir -p %{_target_platform}
|
||||
mkdir %{_target_platform}
|
||||
pushd %{_target_platform}
|
||||
%{qmake_qt5} ..
|
||||
popd
|
||||
@ -207,6 +206,9 @@ popd
|
||||
|
||||
|
||||
%changelog
|
||||
* Mon Jun 08 2015 Rex Dieter <rdieter@fedoraproject.org> 5.4.2-2
|
||||
- restore fix for QTBUG-45753/kde-345544 lost in 5.4.2 rebase
|
||||
|
||||
* Wed Jun 03 2015 Jan Grulich <jgrulich@redhat.com> 5.4.2-1
|
||||
- 5.4.2
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user