Merge lp:~donadigo/pantheon-files/fix-1593748-navigation-items-path into lp:~elementary-apps/pantheon-files/trunk

Proposed by Adam Bieńkowski
Status: Merged
Approved by: Jeremy Wootten
Approved revision: 2200
Merged at revision: 2200
Proposed branch: lp:~donadigo/pantheon-files/fix-1593748-navigation-items-path
Merge into: lp:~elementary-apps/pantheon-files/trunk
Diff against target: 21 lines (+2/-2)
1 file modified
libwidgets/Chrome/TopMenu.vala (+2/-2)
To merge this branch: bzr merge lp:~donadigo/pantheon-files/fix-1593748-navigation-items-path
Reviewer Review Type Date Requested Status
Jeremy Wootten Approve
Review via email: mp+297781@code.launchpad.net

Commit message

* Fix #1593748: "Navigation button items begin with 'file://'".

Description of the change

Fixes #1593748: "Navigation button items begin with 'file://'".

Instead of using GLib method, use the Files one to display correct path to the file, not URI.

To post a comment you must log in.
Revision history for this message
Jeremy Wootten (jeremywootten) wrote :

Works fine, thanks.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'libwidgets/Chrome/TopMenu.vala'
--- libwidgets/Chrome/TopMenu.vala 2016-02-11 11:12:03 +0000
+++ libwidgets/Chrome/TopMenu.vala 2016-06-17 14:42:20 +0000
@@ -118,7 +118,7 @@
118 * in the closure, resulting in a value of n which would always be n=1. So118 * in the closure, resulting in a value of n which would always be n=1. So
119 * by introducting a new variable I can bypass this anoyance.119 * by introducting a new variable I can bypass this anoyance.
120 */120 */
121 var item = new Gtk.MenuItem.with_label (GLib.Uri.unescape_string (path));121 var item = new Gtk.MenuItem.with_label (PF.FileUtils.sanitize_path (path));
122 item.activate.connect (() => {122 item.activate.connect (() => {
123 back(cn);123 back(cn);
124 });124 });
@@ -135,7 +135,7 @@
135 var n = 1;135 var n = 1;
136 foreach (string path in path_list) {136 foreach (string path in path_list) {
137 int cn = n++; /* For explanation look up */137 int cn = n++; /* For explanation look up */
138 var item = new Gtk.MenuItem.with_label (GLib.Uri.unescape_string (path));138 var item = new Gtk.MenuItem.with_label (PF.FileUtils.sanitize_path (path));
139 item.activate.connect (() => {139 item.activate.connect (() => {
140 forward (cn);140 forward (cn);
141 });141 });

Subscribers

People subscribed via source and target branches

to all changes: