author | Antonio Rojas
<arojas@archlinux.org> 2015-04-30 08:31:31 UTC |
committer | Antonio Rojas
<arojas@archlinux.org> 2015-04-30 08:31:31 UTC |
parent | 71440568cd08624e3285c06ce0a7fe926a78d18e |
PKGBUILD | +8 | -3 |
dolphin-places.patch | +122 | -0 |
diff --git a/PKGBUILD b/PKGBUILD index b250ed9..226e236 100644 --- a/PKGBUILD +++ b/PKGBUILD @@ -3,7 +3,7 @@ pkgname=kio pkgver=5.9.0 -pkgrel=1 +pkgrel=2 pkgdesc='Resource and network access abstraction' arch=('i686' 'x86_64') url='https://projects.kde.org/projects/frameworks/kio' @@ -13,11 +13,16 @@ depends=('solid' 'karchive' 'kjobwidgets' 'kbookmarks' 'libxslt' 'kwallet' makedepends=('extra-cmake-modules' 'kdoctools') groups=('kf5') install=kio.install -source=("http://download.kde.org/stable/frameworks/${pkgver%.*}/${pkgname}-${pkgver}.tar.xz") -md5sums=('2fe89d374583bf38a091edc74b9bc1d3') +source=("http://download.kde.org/stable/frameworks/${pkgver%.*}/${pkgname}-${pkgver}.tar.xz" 'dolphin-places.patch') +md5sums=('2fe89d374583bf38a091edc74b9bc1d3' + '9700937823277d19f6f7d440f63f0954') prepare() { mkdir -p build + +# Fix disappearing bookmarks in Dolphin https://bugs.kde.org/show_bug.cgi?id=345174 + cd $pkgname-$pkgver + patch -p1 -i "$srcdir"/dolphin-places.patch } build() { diff --git a/dolphin-places.patch b/dolphin-places.patch new file mode 100644 index 0000000..b087af5 --- /dev/null +++ b/dolphin-places.patch @@ -0,0 +1,122 @@ +From: Emmanuel Pescosta <emmanuelpescosta099@gmail.com> +Date: Mon, 27 Apr 2015 12:15:49 +0000 +Subject: Remove bookmarks syncing from KFilePlacesModel and use user-places.xbel only. +X-Git-Url: http://quickgit.kde.org/?p=kio.git&a=commitdiff&h=e919daeb5b144b146dbf459fadb116729b866d21 +--- +Remove bookmarks syncing from KFilePlacesModel and use user-places.xbel only. + +REVIEW: 123525 +BUG: 345174 +FIXED-IN: 5.10 + +CHANGELOG: Store bookmarks only in user-places.xbel. +--- + + +--- a/src/filewidgets/CMakeLists.txt ++++ b/src/filewidgets/CMakeLists.txt +@@ -23,7 +23,6 @@ + kfilewidget.cpp + kfileplacesitem.cpp + kfileplacesmodel.cpp +- kfileplacessharedbookmarks.cpp + kfileplacesview.cpp + kfileplaceeditdialog.cpp + kfilepreviewgenerator.cpp + +--- a/src/filewidgets/kfileplacesmodel.cpp ++++ b/src/filewidgets/kfileplacesmodel.cpp +@@ -19,7 +19,6 @@ + */ + #include "kfileplacesmodel.h" + #include "kfileplacesitem_p.h" +-#include "kfileplacessharedbookmarks_p.h" + + #ifdef _WIN32_WCE + #include "Windows.h" +@@ -60,10 +59,9 @@ + class KFilePlacesModel::Private + { + public: +- Private(KFilePlacesModel *self) : q(self), bookmarkManager(0), sharedBookmarks(0) {} ++ Private(KFilePlacesModel *self) : q(self), bookmarkManager(0) {} + ~Private() + { +- delete sharedBookmarks; + qDeleteAll(items); + } + +@@ -75,7 +73,6 @@ + + Solid::Predicate predicate; + KBookmarkManager *bookmarkManager; +- KFilePlacesSharedBookmarks *sharedBookmarks; + + void reloadAndSignal(); + QList<KFilePlacesItem *> loadBookmarkList(); +@@ -92,8 +89,8 @@ + KFilePlacesModel::KFilePlacesModel(QObject *parent) + : QAbstractItemModel(parent), d(new Private(this)) + { +- const QString file = QStandardPaths::writableLocation(QStandardPaths::GenericDataLocation) + QLatin1Char('/') + "kfileplaces/bookmarks.xml"; +- d->bookmarkManager = KBookmarkManager::managerForFile(file, "kfilePlaces"); ++ const QString file = QStandardPaths::writableLocation(QStandardPaths::GenericDataLocation) + "/user-places.xbel"; ++ d->bookmarkManager = KBookmarkManager::managerForExternalFile(file); + + // Let's put some places in there if it's empty. We have a corner case here: + // Given you have bookmarked some folders (which have been saved on +@@ -144,9 +141,6 @@ + // user-places.xbel will be filled later). (ereslibre) + d->bookmarkManager->saveAs(file); + } +- +- // create after, so if we have own places, they are added afterwards, in case of equal priorities +- d->sharedBookmarks = new KFilePlacesSharedBookmarks(d->bookmarkManager); + + QString predicate("[[[[ StorageVolume.ignored == false AND [ StorageVolume.usage == 'FileSystem' OR StorageVolume.usage == 'Encrypted' ]]" + " OR " +@@ -656,8 +650,6 @@ + return false; + } + +- d->sharedBookmarks->updateSharedBookmarks(); +- + d->reloadAndSignal(); + + return true; +@@ -684,8 +676,6 @@ + KFilePlacesItem *item = static_cast<KFilePlacesItem *>(after.internalPointer()); + d->bookmarkManager->root().moveBookmark(bookmark, item->bookmark()); + } +- +- d->sharedBookmarks->updateSharedBookmarks(); + + d->reloadAndSignal(); + } +@@ -714,8 +704,6 @@ + bookmark.setIcon(iconName); + bookmark.setMetaDataItem("OnlyInApp", appName); + +- d->sharedBookmarks->updateSharedBookmarks(); +- + d->reloadAndSignal(); + emit dataChanged(index, index); + } +@@ -739,7 +727,6 @@ + } + + d->bookmarkManager->root().deleteBookmark(bookmark); +- d->sharedBookmarks->updateSharedBookmarks(); + d->reloadAndSignal(); + } + +@@ -758,8 +745,6 @@ + } + + bookmark.setMetaDataItem("IsHidden", (hidden ? "true" : "false")); +- +- d->sharedBookmarks->updateSharedBookmarks(); + + d->reloadAndSignal(); + emit dataChanged(index, index); +