Accepting request 258894 from KDE:Frameworks5
- Recommend lang subpackage - Added 0001-ResultsView-Handle-both-Enter-and-Return.patch and 0002-Revert-SourcesModel-Only-consider-each-types-first-r.patch from upstream (kde#339628) OBS-URL: https://build.opensuse.org/request/show/258894 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/milou5?expand=0&rev=7
This commit is contained in:
30
0001-ResultsView-Handle-both-Enter-and-Return.patch
Normal file
30
0001-ResultsView-Handle-both-Enter-and-Return.patch
Normal file
@@ -0,0 +1,30 @@
|
||||
From 5112aff7efb7c2bc74fbe1eb41bc286c37fd706c Mon Sep 17 00:00:00 2001
|
||||
From: Vishesh Handa <me@vhanda.in>
|
||||
Date: Mon, 20 Oct 2014 13:09:43 +0200
|
||||
Subject: [PATCH 1/3] ResultsView: Handle both Enter and Return
|
||||
|
||||
BUG: 339628
|
||||
---
|
||||
lib/qml/ResultsView.qml | 6 ++++++
|
||||
1 file changed, 6 insertions(+)
|
||||
|
||||
diff --git a/lib/qml/ResultsView.qml b/lib/qml/ResultsView.qml
|
||||
index d962703..bbb452a 100644
|
||||
--- a/lib/qml/ResultsView.qml
|
||||
+++ b/lib/qml/ResultsView.qml
|
||||
@@ -77,6 +77,12 @@ ListView {
|
||||
}
|
||||
runCurrentIndex();
|
||||
}
|
||||
+ Keys.onEnterPressed: {
|
||||
+ if (!currentIndex) {
|
||||
+ runAutomatically = true
|
||||
+ }
|
||||
+ runCurrentIndex();
|
||||
+ }
|
||||
|
||||
function runCurrentIndex() {
|
||||
listView.model.run(currentIndex);
|
||||
--
|
||||
2.1.2
|
||||
|
@@ -0,0 +1,35 @@
|
||||
From 366dc912823a0b138c92c9690df3272256b76d01 Mon Sep 17 00:00:00 2001
|
||||
From: Vishesh Handa <me@vhanda.in>
|
||||
Date: Mon, 20 Oct 2014 14:32:47 +0200
|
||||
Subject: [PATCH 2/3] Revert "SourcesModel: Only consider each types first
|
||||
result for priority"
|
||||
|
||||
This reverts commit 3e4bb6b1a7cd3df47b460cd0a7222605eeddd104.
|
||||
|
||||
Only considering the top most item is not ideal as the top most item
|
||||
changes a lot based on which result you pick because krunner tries to
|
||||
remember it.
|
||||
|
||||
Fortunately, the bug is not re-introduced as we did add the extra
|
||||
sorting based on if the visible text contains the query.
|
||||
---
|
||||
lib/sourcesmodel.cpp | 3 +--
|
||||
1 file changed, 1 insertion(+), 2 deletions(-)
|
||||
|
||||
diff --git a/lib/sourcesmodel.cpp b/lib/sourcesmodel.cpp
|
||||
index cae6f06..06a3715 100644
|
||||
--- a/lib/sourcesmodel.cpp
|
||||
+++ b/lib/sourcesmodel.cpp
|
||||
@@ -221,8 +221,7 @@ void SourcesModel::slotMatchesChanged(const QList<Plasma::QueryMatch>& l)
|
||||
QSet<QString> higherTypes;
|
||||
for (QString type: m_types) {
|
||||
const TypeData td = m_matches.value(type);
|
||||
- if (!td.shown.isEmpty()) {
|
||||
- const auto& match = td.shown.first();
|
||||
+ for (const Plasma::QueryMatch& match : td.shown) {
|
||||
if (match.text().contains(m_queryString, Qt::CaseInsensitive)) {
|
||||
QString matchType = match.matchCategory();
|
||||
higherTypes << matchType;
|
||||
--
|
||||
2.1.2
|
||||
|
@@ -1,3 +1,11 @@
|
||||
-------------------------------------------------------------------
|
||||
Sat Oct 25 17:39:11 UTC 2014 - hrvoje.senjan@gmail.com
|
||||
|
||||
- Recommend lang subpackage
|
||||
- Added 0001-ResultsView-Handle-both-Enter-and-Return.patch and
|
||||
0002-Revert-SourcesModel-Only-consider-each-types-first-r.patch
|
||||
from upstream (kde#339628)
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Oct 9 21:24:36 UTC 2014 - hrvoje.senjan@gmail.com
|
||||
|
||||
|
@@ -25,6 +25,10 @@ Group: System/GUI/KDE
|
||||
Url: https://projects.kde.org/milou
|
||||
Source: milou-%{version}.1.tar.xz
|
||||
Source99: %{name}-rpmlintrc
|
||||
# PATCH-FIX-UPSTREAM 0001-ResultsView-Handle-both-Enter-and-Return.patch
|
||||
Patch0: 0001-ResultsView-Handle-both-Enter-and-Return.patch
|
||||
# PATCH-FIX-UPSTREAM 0002-Revert-SourcesModel-Only-consider-each-types-first-r.patch
|
||||
Patch1: 0002-Revert-SourcesModel-Only-consider-each-types-first-r.patch
|
||||
BuildRequires: extra-cmake-modules
|
||||
BuildRequires: fdupes
|
||||
BuildRequires: kdeclarative-devel
|
||||
@@ -37,6 +41,7 @@ BuildRequires: pkgconfig(Qt5Quick) >= 5.2.0
|
||||
BuildRequires: pkgconfig(Qt5Script) >= 5.2.0
|
||||
BuildRequires: pkgconfig(Qt5Test) >= 5.2.0
|
||||
BuildRequires: pkgconfig(Qt5Widgets) >= 5.2.0
|
||||
Recommends: %{name}-lang
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||
|
||||
%description
|
||||
@@ -45,6 +50,8 @@ A dedicated search application built on top of Baloo
|
||||
%lang_package
|
||||
%prep
|
||||
%setup -q -n milou-%{version}
|
||||
%patch0 -p1
|
||||
%patch1 -p1
|
||||
|
||||
%build
|
||||
%cmake_kf5 -d build -- -DCMAKE_INSTALL_LOCALEDIR=share/locale/kf5
|
||||
|
Reference in New Issue
Block a user