[gnome-documents/wip/lokdocview-rebase: 12/13] Use GFile.get_path() to get a native path
- From: Bastien Nocera <hadess src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-documents/wip/lokdocview-rebase: 12/13] Use GFile.get_path() to get a native path
- Date: Fri, 4 Dec 2015 19:25:36 +0000 (UTC)
commit 49480e0c0e3946117d5367eb0025ec8a7de3b9af
Author: Bastien Nocera <hadess hadess net>
Date: Fri Dec 4 19:05:11 2015 +0100
Use GFile.get_path() to get a native path
This means that we can support remote filesystems mounted by GNOME
(like OwnCloud).
src/lokview.js | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/src/lokview.js b/src/lokview.js
index 51f462d..8252591 100644
--- a/src/lokview.js
+++ b/src/lokview.js
@@ -168,7 +168,8 @@ const LOKView = new Lang.Class({
_onLoadFinished: function(manager, doc, docModel) {
if (docModel == null && doc != null) {
- let [ location, ] = GLib.filename_from_uri (doc.uri);
+ let file = Gio.File.new_for_uri (doc.uri);
+ let location = file.get_path();
this._doc = doc;
this.view.open_document(location, "{}", null, Lang.bind(this, this.open_document_cb));
this._progressBar.show();
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]