forked from gentoo/gentoo
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
kde-apps/konqueror: Fix broken address bar w/ >=KF-5.82
KDE-bug: https://bugs.kde.org/show_bug.cgi?id=437161 Package-Manager: Portage-3.0.19, Repoman-3.0.3 Signed-off-by: Andreas Sturmlechner <[email protected]>
- Loading branch information
Showing
2 changed files
with
157 additions
and
0 deletions.
There are no files selected for viewing
67 changes: 67 additions & 0 deletions
67
kde-apps/konqueror/files/konqueror-21.04.1-use-new-QComboBox-signal.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
From f4a3fec5a229fea59eba15b8644a06a9e16e91a0 Mon Sep 17 00:00:00 2001 | ||
From: Jonathan Marten <[email protected]> | ||
Date: Sun, 16 May 2021 14:07:56 +0000 | ||
Subject: [PATCH] KonqCombo: Use new QComboBox signal and new-style connect | ||
|
||
(cherry picked from commit 1003724180b3a758f7f4f42b247261ac95234e1b) | ||
--- | ||
src/konqcombo.cpp | 26 +++++++++++++------------- | ||
1 file changed, 13 insertions(+), 13 deletions(-) | ||
|
||
diff --git a/src/konqcombo.cpp b/src/konqcombo.cpp | ||
index f401aca3f..84daa8078 100644 | ||
--- a/src/konqcombo.cpp | ||
+++ b/src/konqcombo.cpp | ||
@@ -143,9 +143,7 @@ KonqCombo::KonqCombo(QWidget *parent) | ||
edit->setCompletionBox(new KonqComboCompletionBox(edit)); | ||
setLineEdit(edit); | ||
setItemDelegate(new KonqComboItemDelegate(this)); | ||
- | ||
- connect(edit, SIGNAL(textEdited(QString)), | ||
- this, SLOT(slotTextEdited(QString))); | ||
+ connect(edit, &QLineEdit::textEdited, this, &KonqCombo::slotTextEdited); | ||
|
||
completionBox()->setTabHandling(true); // #167135 | ||
completionBox()->setItemDelegate(new KonqComboItemDelegate(this)); | ||
@@ -156,16 +154,18 @@ KonqCombo::KonqCombo(QWidget *parent) | ||
// Connect to the returnPressed signal when completionMode == CompletionNone. #314736 | ||
slotCompletionModeChanged(completionMode()); | ||
|
||
- connect(KonqHistoryManager::kself(), SIGNAL(cleared()), SLOT(slotCleared())); | ||
- connect(this, &KonqCombo::cleared, this, &KonqCombo::slotCleared); | ||
- connect(this, static_cast<void (KonqCombo::*)(int)>(&KonqCombo::highlighted), this, &KonqCombo::slotSetIcon); | ||
+ connect(KonqHistoryManager::kself(), &KParts::HistoryProvider::cleared, this, &KonqCombo::slotCleared); | ||
+ connect(this, &KHistoryComboBox::cleared, this, &KonqCombo::slotCleared); | ||
+ // The overload resolution is still needed until QComboBox::highlight(QString) | ||
+ // is either removed or hidden. | ||
+ connect(this, QOverload<int>::of(&QComboBox::highlighted), this, &KonqCombo::slotSetIcon); | ||
|
||
- // WARNING! has to be the old style connect below, otherwise location bar doesn't work! | ||
- //connect(this, &KonqCombo::activated, this, &KonqCombo::slotActivated); | ||
+#if QT_VERSION >= QT_VERSION_CHECK(5,15,0) | ||
+ connect(this, &QComboBox::textActivated, this, &KonqCombo::slotActivated); | ||
+#else | ||
connect(this, SIGNAL(activated(QString)), this, SLOT(slotActivated(QString))); | ||
- | ||
- connect(this, SIGNAL(completionModeChanged(KCompletion::CompletionMode)), | ||
- this, SLOT(slotCompletionModeChanged(KCompletion::CompletionMode))); | ||
+#endif | ||
+ connect(this, &KComboBox::completionModeChanged, this, &KonqCombo::slotCompletionModeChanged); | ||
} | ||
|
||
KonqCombo::~KonqCombo() | ||
@@ -680,9 +680,9 @@ void KonqCombo::slotReturnPressed() | ||
void KonqCombo::slotCompletionModeChanged(KCompletion::CompletionMode mode) | ||
{ | ||
if (mode == KCompletion::CompletionNone) { | ||
- connect(this, static_cast<void (KonqCombo::*)()>(&KonqCombo::returnPressed), this, &KonqCombo::slotReturnPressed); | ||
+ connect(this, QOverload<const QString &>::of(&KComboBox::returnPressed), this, &KonqCombo::slotReturnPressed); | ||
} else { | ||
- disconnect(this, static_cast<void (KonqCombo::*)()>(&KonqCombo::returnPressed), this, &KonqCombo::slotReturnPressed); | ||
+ disconnect(this, QOverload<const QString &>::of(&KComboBox::returnPressed), this, &KonqCombo::slotReturnPressed); | ||
} | ||
} | ||
|
||
-- | ||
GitLab | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,90 @@ | ||
# Copyright 1999-2021 Gentoo Authors | ||
# Distributed under the terms of the GNU General Public License v2 | ||
|
||
EAPI=7 | ||
|
||
ECM_HANDBOOK="optional" | ||
ECM_TEST="true" | ||
KFMIN=5.80.0 | ||
QTMIN=5.15.2 | ||
VIRTUALX_REQUIRED="test" | ||
inherit flag-o-matic ecm kde.org optfeature | ||
|
||
DESCRIPTION="Web browser and file manager based on KDE Frameworks" | ||
HOMEPAGE="https://apps.kde.org/konqueror/" | ||
|
||
LICENSE="GPL-2" # TODO: CHECK | ||
SLOT="5" | ||
KEYWORDS="~amd64 ~arm64 ~x86" | ||
IUSE="activities speech X" | ||
|
||
# 4 of 4 tests fail. Last checked for 4.0.3 | ||
RESTRICT+=" test" | ||
|
||
COMMON_DEPEND=" | ||
>=dev-qt/qtdbus-${QTMIN}:5 | ||
>=dev-qt/qtgui-${QTMIN}:5 | ||
>=dev-qt/qtwebengine-${QTMIN}:5[widgets] | ||
>=dev-qt/qtwidgets-${QTMIN}:5 | ||
>=dev-qt/qtxml-${QTMIN}:5 | ||
>=kde-frameworks/karchive-${KFMIN}:5 | ||
>=kde-frameworks/kbookmarks-${KFMIN}:5 | ||
>=kde-frameworks/kcmutils-${KFMIN}:5 | ||
>=kde-frameworks/kcodecs-${KFMIN}:5 | ||
>=kde-frameworks/kcompletion-${KFMIN}:5 | ||
>=kde-frameworks/kconfig-${KFMIN}:5 | ||
>=kde-frameworks/kconfigwidgets-${KFMIN}:5 | ||
>=kde-frameworks/kcoreaddons-${KFMIN}:5 | ||
>=kde-frameworks/kcrash-${KFMIN}:5 | ||
>=kde-frameworks/kdbusaddons-${KFMIN}:5 | ||
>=kde-frameworks/kdesu-${KFMIN}:5 | ||
>=kde-frameworks/kguiaddons-${KFMIN}:5 | ||
>=kde-frameworks/ki18n-${KFMIN}:5 | ||
>=kde-frameworks/kiconthemes-${KFMIN}:5 | ||
>=kde-frameworks/kio-${KFMIN}:5 | ||
>=kde-frameworks/kitemviews-${KFMIN}:5 | ||
>=kde-frameworks/kjobwidgets-${KFMIN}:5 | ||
>=kde-frameworks/kparts-${KFMIN}:5 | ||
>=kde-frameworks/kservice-${KFMIN}:5 | ||
>=kde-frameworks/kwallet-${KFMIN}:5 | ||
>=kde-frameworks/kwidgetsaddons-${KFMIN}:5 | ||
>=kde-frameworks/kwindowsystem-${KFMIN}:5 | ||
>=kde-frameworks/kxmlgui-${KFMIN}:5 | ||
sys-libs/zlib | ||
speech? ( >=dev-qt/qtspeech-${QTMIN}:5 ) | ||
X? ( >=dev-qt/qtx11extras-${QTMIN}:5 ) | ||
" | ||
DEPEND="${COMMON_DEPEND} | ||
activities? ( >=kde-frameworks/kactivities-${KFMIN}:5 ) | ||
" | ||
RDEPEND="${COMMON_DEPEND} | ||
kde-apps/kfind:5 | ||
kde-plasma/kde-cli-tools:5 | ||
" | ||
|
||
PATCHES=( "${FILESDIR}/${P}-use-new-QComboBox-signal.patch" ) # KDE-bug 437161 | ||
|
||
src_prepare() { | ||
[[ ${CHOST} == *-solaris* ]] && append-ldflags -lmalloc | ||
|
||
ecm_src_prepare | ||
} | ||
|
||
src_configure() { | ||
local mycmakeargs=( | ||
$(cmake_use_find_package activities KF5Activities) | ||
$(cmake_use_find_package speech Qt5TextToSpeech) | ||
$(cmake_use_find_package X X11) | ||
) | ||
ecm_src_configure | ||
} | ||
|
||
pkg_postinst() { | ||
if [[ -z "${REPLACING_VERSIONS}" ]]; then | ||
optfeature "bookmarks support" kde-apps/keditbookmarks:${SLOT} | ||
optfeature "filemanager component" kde-apps/dolphin:${SLOT} | ||
optfeature "SVG support" kde-apps/svg:${SLOT} | ||
optfeature "Java support on webpages" virtual/jre | ||
fi | ||
ecm_pkg_postinst | ||
} |