From 619569909b858d304c813ffa1ee73fc029474ccfd6ac8b977e1d385a7bac34aa Mon Sep 17 00:00:00 2001 From: Antonio Larrosa Date: Thu, 13 Feb 2020 17:26:11 +0000 Subject: [PATCH] Accepting request 774218 from home:alarrosa:branches:multimedia:apps - Add patch to fix a crash when right-clicking on the cover art box. * 0001-Fix-crash-on-PyQt-ge-5.14-on-cover-art-context-menu.patch OBS-URL: https://build.opensuse.org/request/show/774218 OBS-URL: https://build.opensuse.org/package/show/multimedia:apps/picard?expand=0&rev=76 --- ...Qt-ge-5.14-on-cover-art-context-menu.patch | 37 +++++++++++++++++++ picard.changes | 6 +++ picard.spec | 4 +- 3 files changed, 46 insertions(+), 1 deletion(-) create mode 100644 0001-Fix-crash-on-PyQt-ge-5.14-on-cover-art-context-menu.patch diff --git a/0001-Fix-crash-on-PyQt-ge-5.14-on-cover-art-context-menu.patch b/0001-Fix-crash-on-PyQt-ge-5.14-on-cover-art-context-menu.patch new file mode 100644 index 0000000..2d2167d --- /dev/null +++ b/0001-Fix-crash-on-PyQt-ge-5.14-on-cover-art-context-menu.patch @@ -0,0 +1,37 @@ +From 32e05058e0ac5772d7a480287ee428642fbbc9b9 Mon Sep 17 00:00:00 2001 +From: Philipp Wolfer +Date: Tue, 7 Jan 2020 08:22:13 +0100 +Subject: [PATCH] PICARD-1700: Fix crash on PyQt >= 5.14 on cover art context + menu + +In PyQt 5.14 the exclusive parameter for QActionGroup is no longer available. Also QActionGroup is exclusive by default in Qt5, so there is no need to set this. +--- + picard/ui/coverartbox.py | 2 +- + picard/ui/logview.py | 1 - + 2 files changed, 1 insertion(+), 2 deletions(-) + +diff --git a/picard/ui/coverartbox.py b/picard/ui/coverartbox.py +index 102704184..bde1c06f5 100644 +--- a/picard/ui/coverartbox.py ++++ b/picard/ui/coverartbox.py +@@ -538,7 +538,7 @@ def contextMenuEvent(self, event): + if not menu.isEmpty(): + menu.addSeparator() + +- load_image_behavior_group = QtWidgets.QActionGroup(self.parent, exclusive=True) ++ load_image_behavior_group = QtWidgets.QActionGroup(self.parent) + action = load_image_behavior_group.addAction(QtWidgets.QAction(_('Replace front cover art on drop'), self.parent, checkable=True)) + action.triggered.connect(partial(self.set_load_image_behavior, behavior='replace')) + if config.setting["load_image_behavior"] == 'replace': +diff --git a/picard/ui/logview.py b/picard/ui/logview.py +index cf75feadd..7bb7813c0 100644 +--- a/picard/ui/logview.py ++++ b/picard/ui/logview.py +@@ -129,7 +129,6 @@ def __init__(self, parent=None): + super().__init__(parent=parent) + + self.action_group = QtWidgets.QActionGroup(self) +- self.action_group .setExclusive(True) + self.actions = {} + for level, feat in log.levels_features.items(): + act = QtWidgets.QAction(_(feat.name), self, checkable=True) diff --git a/picard.changes b/picard.changes index b0d7e1f..0be3979 100644 --- a/picard.changes +++ b/picard.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Thu Feb 13 16:25:33 UTC 2020 - Antonio Larrosa + +- Add patch to fix a crash when right-clicking on the cover art box. + * 0001-Fix-crash-on-PyQt-ge-5.14-on-cover-art-context-menu.patch + ------------------------------------------------------------------- Mon Nov 11 21:10:07 UTC 2019 - Jaime Marquínez Ferrándiz diff --git a/picard.spec b/picard.spec index 006c43d..c6f8f2a 100644 --- a/picard.spec +++ b/picard.spec @@ -1,7 +1,7 @@ # # spec file for package picard # -# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2020 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -24,6 +24,7 @@ License: GPL-2.0-or-later Group: Productivity/Multimedia/Sound/Utilities URL: https://picard.musicbrainz.org Source0: https://codeload.github.com/metabrainz/picard/tar.gz/release-%{version}#/%{name}-%{version}.tar.gz +Patch0: 0001-Fix-crash-on-PyQt-ge-5.14-on-cover-art-context-menu.patch BuildRequires: desktop-file-utils BuildRequires: gcc-c++ BuildRequires: hicolor-icon-theme @@ -48,6 +49,7 @@ track-based tagging. %prep %setup -q -n %{name}-release-%{version} +%patch0 -p1 %build export LANG=en_US.UTF-8