forked from pool/konqueror
Accepting request 757319 from home:wolfi323:branches:KDE:Applications
- Add upstream patch to make closing a tab via its close button work again: * Restore-ability-to-close-tab-by-clicking-on-close-button.patch OBS-URL: https://build.opensuse.org/request/show/757319 OBS-URL: https://build.opensuse.org/package/show/KDE:Applications/konqueror?expand=0&rev=126
This commit is contained in:
parent
9e48f95f5b
commit
8fd6e397f1
@ -0,0 +1,74 @@
|
||||
From 919076fa77a216c7ad592eb7420d78169d8631b7 Mon Sep 17 00:00:00 2001
|
||||
From: Stefano Crocco <stefano.crocco@alice.it>
|
||||
Date: Sun, 3 Nov 2019 19:15:24 +0100
|
||||
Subject: Restore ability to close tab by clicking on close button
|
||||
|
||||
Summary:
|
||||
After making KTabBar and KTabWidget part of Konqueror, clicking on the close
|
||||
button of a tab didn't make the tab close any longer. This fixes it
|
||||
|
||||
Test Plan:
|
||||
Open several tabs in Konqueror, then click on their close button and
|
||||
check that they close. Check that when only one tab remains, the tab bar is
|
||||
hidden
|
||||
|
||||
Reviewers: dfaure
|
||||
|
||||
Reviewed By: dfaure
|
||||
|
||||
Differential Revision: https://phabricator.kde.org/D25662
|
||||
---
|
||||
src/konqtabs.cpp | 8 ++++----
|
||||
src/konqtabs.h | 2 +-
|
||||
2 files changed, 5 insertions(+), 5 deletions(-)
|
||||
|
||||
diff --git a/src/konqtabs.cpp b/src/konqtabs.cpp
|
||||
index 9858bd6..53a5440 100644
|
||||
--- a/src/konqtabs.cpp
|
||||
+++ b/src/konqtabs.cpp
|
||||
@@ -83,7 +83,7 @@ KonqFrameTabs::KonqFrameTabs(QWidget *parent, KonqFrameContainerBase *parentCont
|
||||
if (KonqSettings::tabPosition() == QLatin1String("Bottom")) {
|
||||
setTabPosition(QTabWidget::South);
|
||||
}
|
||||
- connect(this, SIGNAL(closeRequest(QWidget*)), SLOT(slotCloseRequest(QWidget*)));
|
||||
+ connect(this, &KonqFrameTabs::tabCloseRequested, this, &KonqFrameTabs::slotCloseRequest);
|
||||
connect(this, SIGNAL(removeTabPopup()),
|
||||
m_pViewManager->mainWindow(), SLOT(slotRemoveTabPopup()));
|
||||
|
||||
@@ -352,9 +352,9 @@ void KonqFrameTabs::refreshSubPopupMenuTab()
|
||||
m_pViewManager->mainWindow()->action("removeothertabs")->shortcut());
|
||||
}
|
||||
|
||||
-void KonqFrameTabs::slotCloseRequest(QWidget *w)
|
||||
+void KonqFrameTabs::slotCloseRequest(int idx)
|
||||
{
|
||||
- m_pViewManager->mainWindow()->setWorkingTab(indexOf(w));
|
||||
+ m_pViewManager->mainWindow()->setWorkingTab(idx);
|
||||
emit removeTabPopup();
|
||||
}
|
||||
|
||||
@@ -614,7 +614,7 @@ bool KonqFrameTabs::eventFilter(QObject *watched, QEvent *event)
|
||||
if (e->button() == Qt::MidButton) {
|
||||
if (event->type() == QEvent::MouseButtonRelease) {
|
||||
const int index = bar->tabAt(e->pos());
|
||||
- slotCloseRequest(widget(index));
|
||||
+ slotCloseRequest(index);
|
||||
}
|
||||
e->accept();
|
||||
return true;
|
||||
diff --git a/src/konqtabs.h b/src/konqtabs.h
|
||||
index 3ce3548..01091ea 100644
|
||||
--- a/src/konqtabs.h
|
||||
+++ b/src/konqtabs.h
|
||||
@@ -138,7 +138,7 @@ private:
|
||||
private Q_SLOTS:
|
||||
void slotContextMenu(const QPoint &);
|
||||
void slotContextMenu(QWidget *, const QPoint &);
|
||||
- void slotCloseRequest(QWidget *);
|
||||
+ void slotCloseRequest(int);
|
||||
void slotMovedTab(int, int);
|
||||
void slotMouseMiddleClick();
|
||||
void slotMouseMiddleClick(QWidget *);
|
||||
--
|
||||
cgit v1.1
|
||||
|
@ -1,3 +1,10 @@
|
||||
-------------------------------------------------------------------
|
||||
Mon Dec 16 11:28:42 UTC 2019 - Wolfgang Bauer <wbauer@tmo.at>
|
||||
|
||||
- Add upstream patch to make closing a tab via its close button
|
||||
work again:
|
||||
* Restore-ability-to-close-tab-by-clicking-on-close-button.patch
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Dec 10 06:38:48 UTC 2019 - Luca Beltrame <lbeltrame@kde.org>
|
||||
|
||||
|
@ -34,6 +34,8 @@ Source: https://download.kde.org/stable/release-service/%{version}/src/%
|
||||
Source1: https://download.kde.org/stable/release-service/%{version}/src/%{name}-%{version}.tar.xz.sig
|
||||
Source2: applications.keyring
|
||||
%endif
|
||||
# PATCH-FIX-UPSTREAM
|
||||
Patch0: Restore-ability-to-close-tab-by-clicking-on-close-button.patch
|
||||
BuildRequires: extra-cmake-modules
|
||||
BuildRequires: kf5-filesystem
|
||||
BuildRequires: libtidy-devel
|
||||
@ -121,6 +123,7 @@ Development package for the konqueror libraries.
|
||||
|
||||
%prep
|
||||
%setup -q
|
||||
%autopatch -p1
|
||||
|
||||
%build
|
||||
%if 0%{?suse_version} < 1330
|
||||
|
Loading…
Reference in New Issue
Block a user