[gnome-shell-extensions/gnome-3-6] PlacesMenu: ignore missing local bookmarks
- From: Giovanni Campagna <gcampagna src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell-extensions/gnome-3-6] PlacesMenu: ignore missing local bookmarks
- Date: Fri, 16 Nov 2012 19:32:21 +0000 (UTC)
commit f1eb846b479f2ad7d118a65f163291a57299eb65
Author: Giovanni Campagna <gcampagna src gnome org>
Date: Fri Nov 16 20:29:01 2012 +0100
PlacesMenu: ignore missing local bookmarks
If a local bookmark does not refer to an existing directory, ignore
it instead of showing a broken entry.
extensions/places-menu/placeDisplay.js | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/extensions/places-menu/placeDisplay.js b/extensions/places-menu/placeDisplay.js
index fdb7ada..0d3c5c6 100644
--- a/extensions/places-menu/placeDisplay.js
+++ b/extensions/places-menu/placeDisplay.js
@@ -277,6 +277,9 @@ const PlacesManager = new Lang.Class({
continue;
let file = Gio.File.new_for_uri(bookmark);
+ if (file.is_native() && !file.query_exists(null))
+ continue;
+
let duplicate = false;
for (let i = 0; i < this._places.special.length; i++) {
if (file.equal(this._places.special[i].file)) {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]