summaryrefslogtreecommitdiff
path: root/app-text/kjots
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2020-04-25 11:37:10 +0100
committerV3n3RiX <venerix@redcorelinux.org>2020-04-25 11:37:10 +0100
commit38423c67c8a23f6a1bc42038193182e2da3116eb (patch)
tree04e2cf4bd43601b77daa79fe654e409187093c5e /app-text/kjots
parent623ee73d661e5ed8475cb264511f683407d87365 (diff)
gentoo resync : 25.04.2020
Diffstat (limited to 'app-text/kjots')
-rw-r--r--app-text/kjots/Manifest2
-rw-r--r--app-text/kjots/files/kjots-5.0.2-kf5bookmarks-5.69.patch67
-rw-r--r--app-text/kjots/kjots-5.0.2-r1.ebuild55
3 files changed, 124 insertions, 0 deletions
diff --git a/app-text/kjots/Manifest b/app-text/kjots/Manifest
index 4c0890a724f5..71e4615571c0 100644
--- a/app-text/kjots/Manifest
+++ b/app-text/kjots/Manifest
@@ -1,3 +1,5 @@
+AUX kjots-5.0.2-kf5bookmarks-5.69.patch 2734 BLAKE2B 5bbad18ee50f844320a405347eb6f89535b831d42b4751c56d7227e31095dbf0767fff15ea5fe3930bb11a13155bd13db6f9b970be86aee011c0929efaa7dbfe SHA512 13aff021919d8565cce1c6e7c84cdf23e9a405394374451325f229a00ce5d36be070c0efb0726573297a615d709e0a7d1bd60cb5f1e7752aaee50d8021b64fef
DIST kjots-5.0.2.tar.xz 230608 BLAKE2B 3194b0ef072decfa09455ca7e8d6057ea3f37f54d37641a6ddf28e17ef4662a408adc9e9b04394e6002b51e72ef740412bcdd70324d6efcb9e949f9911437559 SHA512 a652765c56cebcaeba7b879cc075555c28667abdba84d11e986e5ffb440fbc776116f363992dd84d939918ae7d80ef5c2e1093da28d114b18041e10e5209b225
+EBUILD kjots-5.0.2-r1.ebuild 1469 BLAKE2B 0e66e6554360a201f1095861cc6f5a65fe5f4ac5b344f4f55ebd87b350c5e412782f5e75f5e56f64a36df1250aebf45d9d07d6afcb4b93f879df50cc1087bf06 SHA512 04e3be8661fb2eff2dd22373fea6c6fb12ce49cac076e661cbf1af9538742405bf71d84f6dcace4c07a5c451639694b6b2dd31c11af11d7a07f1a4a3a7795f90
EBUILD kjots-5.0.2.ebuild 1239 BLAKE2B d6974d518f55bdbee067441c9d83c3ef23605ddd45869105ec55fcc8334f0673f983c7f91757b72a2155deef2f4cecad00a494cf602437a3836ca66e1049c4f1 SHA512 6cc4b6374ff97e146927f04723a76d55f534a554a13d12b9fd3d2fcaaddba0625d282af9975269845dfcc1733ffc93e2060581a378326b6317dbc44cf347afb9
MISC metadata.xml 249 BLAKE2B ad415db89e5dee1627aa77f44ded9d4e1e5b8217d06c7ca25bbaa3fe92ce67c2b1090957c45a821b407d7927e5af798498aa6a5b903895ee1af8ee20a446c7f7 SHA512 76a5a340b13f0053ca3c5e94ed24380ea8d29b45ac8655419e22eaadb1e4a827c04d2e7e36b65145c4964e6526f656618fc6ac144e277ef53cb7373e6239e3c3
diff --git a/app-text/kjots/files/kjots-5.0.2-kf5bookmarks-5.69.patch b/app-text/kjots/files/kjots-5.0.2-kf5bookmarks-5.69.patch
new file mode 100644
index 000000000000..63bda683122f
--- /dev/null
+++ b/app-text/kjots/files/kjots-5.0.2-kf5bookmarks-5.69.patch
@@ -0,0 +1,67 @@
+From ca6f4b963e83ed91cc7314e1b60fe6607b61b53e Mon Sep 17 00:00:00 2001
+From: Igor Poboiko <igor.poboiko@gmail.com>
+Date: Sun, 12 Apr 2020 17:55:24 +0300
+Subject: [KJots] Fix bookmarks actions
+
+Summary:
+This patch ports KJots from deprecated `KBookmarksMenu` API (see {D25660}).
+
+On my machine, it also fixes a crash (`bm_action` was null for some reason,
+I did not investigate it though).
+
+It also fixes the shortcuts collision (`action->setShortcut` was not enough,
+one also needs to run `actionCollection->setDefaultShortcut`).
+
+BUG: 384000
+
+Test Plan:
+1) Start KJots
+2) It don't crash, and `Ambiguous shortcuts` dialog does not appear)
+3) Open `Bookmarks` menu, the shortcut is `Ctrl+Shift+B`.
+
+Reviewers: dvratil
+
+Reviewed By: dvratil
+
+Subscribers: winterz, kde-pim
+
+Tags: #kde_pim
+
+Differential Revision: https://phabricator.kde.org/D28775
+---
+ src/kjotswidget.cpp | 13 ++++++++-----
+ 1 file changed, 8 insertions(+), 5 deletions(-)
+
+diff --git a/src/kjotswidget.cpp b/src/kjotswidget.cpp
+index 865129b..e343bbd 100644
+--- a/src/kjotswidget.cpp
++++ b/src/kjotswidget.cpp
+@@ -353,17 +353,20 @@ KJotsWidget::KJotsWidget(QWidget *parent, KXMLGUIClient *xmlGuiClient, Qt::Windo
+ bookmarkMenu = actionCollection->add<KActionMenu>(QLatin1String("bookmarks"));
+ bookmarkMenu->setText(i18n("&Bookmarks"));
+ KJotsBookmarks *bookmarks = new KJotsBookmarks(treeview);
+- /*KBookmarkMenu *bmm =*/ new KBookmarkMenu(
++ KBookmarkMenu *bmm = new KBookmarkMenu(
+ KBookmarkManager::managerForFile(
+ QStandardPaths::standardLocations(QStandardPaths::AppDataLocation).first() + QStringLiteral("/kjots/bookmarks.xml"),
+ QStringLiteral("kjots")),
+- bookmarks, bookmarkMenu->menu(), actionCollection);
++ bookmarks, bookmarkMenu->menu());
+
+ // "Add bookmark" and "make text bold" actions have conflicting shortcuts (ctrl + b)
+ // Make add_bookmark use ctrl+shift+b to resolve that.
+- QAction *bm_action = qobject_cast<QAction *>(actionCollection->action(QLatin1String("add_bookmark")));
+- Q_ASSERT(bm_action);
+- bm_action->setShortcut(Qt::CTRL + Qt::SHIFT + Qt::Key_B);
++ QAction *bm_action = bmm->addBookmarkAction();
++ actionCollection->addAction(QStringLiteral("add_bookmark"), bm_action);
++ actionCollection->setDefaultShortcut(bm_action, Qt::CTRL | Qt::SHIFT | Qt::Key_B);
++ actionCollection->addAction(QStringLiteral("edit_bookmark"), bmm->editBookmarksAction());
++ actionCollection->addAction(QStringLiteral("add_bookmarks_list"), bmm->bookmarkTabsAsFolderAction());
++
+
+ KStandardAction::find(this, SLOT(onShowSearch()), actionCollection);
+ action = KStandardAction::findNext(this, SLOT(onRepeatSearch()), actionCollection);
+--
+cgit v1.1
+
diff --git a/app-text/kjots/kjots-5.0.2-r1.ebuild b/app-text/kjots/kjots-5.0.2-r1.ebuild
new file mode 100644
index 000000000000..d5159f4edb3b
--- /dev/null
+++ b/app-text/kjots/kjots-5.0.2-r1.ebuild
@@ -0,0 +1,55 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+KFMIN=5.60.0
+QTMIN=5.12.3
+inherit ecm kde.org
+
+DESCRIPTION="Note taking utility by KDE"
+HOMEPAGE="https://userbase.kde.org/KJots https://community.kde.org/PIM/KJots"
+SRC_URI="mirror://kde/stable/${PN}/${PV}/${P}.tar.xz"
+
+LICENSE="GPL-2"
+SLOT="5"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+# drop kbookmarks subslot operator when KFMIN >= 5.69.0
+DEPEND="
+ dev-libs/grantlee:5
+ dev-libs/libxslt
+ >=dev-qt/qtdbus-${QTMIN}:5
+ >=dev-qt/qtgui-${QTMIN}:5
+ >=dev-qt/qtprintsupport-${QTMIN}:5
+ >=dev-qt/qtwidgets-${QTMIN}:5
+ >=kde-apps/akonadi-19.04.3:5
+ >=kde-apps/akonadi-notes-19.04.3:5
+ >=kde-apps/kmime-19.04.3:5
+ >=kde-apps/kontactinterface-19.04.3:5
+ >=kde-apps/kpimtextedit-19.04.3:5
+ >=kde-frameworks/kbookmarks-${KFMIN}:5=
+ >=kde-frameworks/kcmutils-${KFMIN}:5
+ >=kde-frameworks/kconfig-${KFMIN}:5
+ >=kde-frameworks/kconfigwidgets-${KFMIN}:5
+ >=kde-frameworks/kcoreaddons-${KFMIN}:5
+ >=kde-frameworks/ki18n-${KFMIN}:5
+ >=kde-frameworks/kio-${KFMIN}:5
+ >=kde-frameworks/kitemmodels-${KFMIN}:5
+ >=kde-frameworks/kparts-${KFMIN}:5
+ >=kde-frameworks/ktextwidgets-${KFMIN}:5
+ >=kde-frameworks/kwidgetsaddons-${KFMIN}:5
+ >=kde-frameworks/kxmlgui-${KFMIN}:5
+"
+RDEPEND="${DEPEND}
+ !app-text/kjots:4
+"
+
+src_prepare() {
+ if has_version ">=kde-frameworks/kbookmarks-5.69"; then
+ PATCHES+=( "${FILESDIR}/${P}-kf5bookmarks-5.69.patch" ) # KDE-Bug 384000
+ fi
+
+ ecm_src_prepare
+}