Accepting request 687644 from KDE:Frameworks5
OBS-URL: https://build.opensuse.org/request/show/687644 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/kcmutils?expand=0&rev=65
This commit is contained in:
commit
5a3896f363
46
Add-runtime-guard-that-pages-are-KCMs-in-KCMultiDialog.patch
Normal file
46
Add-runtime-guard-that-pages-are-KCMs-in-KCMultiDialog.patch
Normal file
@ -0,0 +1,46 @@
|
||||
From d9ddd3524535ecb5debc2157ddf02922b6bb1685 Mon Sep 17 00:00:00 2001
|
||||
From: David Edmundson <kde@davidedmundson.co.uk>
|
||||
Date: Tue, 19 Mar 2019 18:23:24 +0100
|
||||
Subject: Add runtime guard that pages are KCMs in KCMultiDialog
|
||||
|
||||
Summary:
|
||||
This situation can come up if a KCMultiDialog subclass adds pages
|
||||
directly that aren't KCModules.
|
||||
|
||||
BUG: 405440
|
||||
|
||||
Test Plan: acheronuk tested this patch on a crashing example
|
||||
|
||||
Subscribers: kde-frameworks-devel
|
||||
|
||||
Tags: #frameworks
|
||||
|
||||
Differential Revision: https://phabricator.kde.org/D19888
|
||||
---
|
||||
src/kcmultidialog.cpp | 3 +--
|
||||
1 file changed, 1 insertion(+), 2 deletions(-)
|
||||
|
||||
diff --git a/src/kcmultidialog.cpp b/src/kcmultidialog.cpp
|
||||
index 9ddd43b..b689f27 100644
|
||||
--- a/src/kcmultidialog.cpp
|
||||
+++ b/src/kcmultidialog.cpp
|
||||
@@ -99,7 +99,6 @@ void KCMultiDialogPrivate::_k_slotCurrentPageChanged(KPageWidgetItem *current, K
|
||||
currentModule = modules[i].kcm;
|
||||
}
|
||||
}
|
||||
- Q_ASSERT(currentModule);
|
||||
|
||||
// For some reason the KCModuleQml modules handle their own margin internally
|
||||
// to match that we need to adjust the spacing of our page widget
|
||||
@@ -108,7 +107,7 @@ void KCMultiDialogPrivate::_k_slotCurrentPageChanged(KPageWidgetItem *current, K
|
||||
|
||||
// TODO KF6 Fix this situation.
|
||||
|
||||
- if (currentModule->realModule() && currentModule->realModule()->inherits("KCModuleQml")) {
|
||||
+ if (currentModule && currentModule->realModule() && currentModule->realModule()->inherits("KCModuleQml")) {
|
||||
bool padHackLeft = false;
|
||||
bool padHackRight = false;
|
||||
if (q->pageWidget()->model()->rowCount() < 2) {
|
||||
--
|
||||
cgit v1.1
|
||||
|
@ -1,3 +1,9 @@
|
||||
-------------------------------------------------------------------
|
||||
Wed Mar 20 17:03:22 UTC 2019 - wbauer@tmo.at
|
||||
|
||||
- Add Add-runtime-guard-that-pages-are-KCMs-in-KCMultiDialog.patch
|
||||
to fix Kontact crash when opening its settings (kde#405440)
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Sun Mar 10 20:15:35 UTC 2019 - lbeltrame@kde.org
|
||||
|
||||
|
@ -32,6 +32,8 @@ Group: System/GUI/KDE
|
||||
URL: https://www.kde.org
|
||||
Source: http://download.kde.org/stable/frameworks/%{_tar_path}/%{name}-%{version}.tar.xz
|
||||
Source1: baselibs.conf
|
||||
# PATCH-FIX-UPSTREAM
|
||||
Patch0: Add-runtime-guard-that-pages-are-KCMs-in-KCMultiDialog.patch
|
||||
BuildRequires: cmake >= 3.0
|
||||
BuildRequires: extra-cmake-modules >= %{_kf5_bugfix_version}
|
||||
BuildRequires: fdupes
|
||||
@ -86,6 +88,7 @@ created with the KConfigWidgets framework. Development files.
|
||||
%if 0%{?suse_version} == 1500
|
||||
sed -i -e "s/^set *(REQUIRED_QT_VERSION 5.10.0)$/set(REQUIRED_QT_VERSION 5.9.0)/" CMakeLists.txt
|
||||
%endif
|
||||
%autopatch -p1
|
||||
|
||||
%build
|
||||
%cmake_kf5 -d build
|
||||
|
Loading…
Reference in New Issue
Block a user