[meld] recent: Don't use the URI as the display name
- From: Kai Willadsen <kaiw src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [meld] recent: Don't use the URI as the display name
- Date: Sat, 18 Nov 2017 21:41:26 +0000 (UTC)
commit a5808e04347f11acfb83ef157698969d8b5ac1fc
Author: Kai Willadsen <kai willadsen gmail com>
Date: Fri Nov 17 06:12:45 2017 +1000
recent: Don't use the URI as the display name
meld/recent.py | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
---
diff --git a/meld/recent.py b/meld/recent.py
index e64360e..dfdee4e 100644
--- a/meld/recent.py
+++ b/meld/recent.py
@@ -89,6 +89,7 @@ class RecentFiles(object):
return
uris = [f.get_uri() for f in gfiles]
+ names = [f.get_parse_name() for f in gfiles]
# If a (type, uris) comparison is already registered, then re-add
# the corresponding comparison file
@@ -102,9 +103,9 @@ class RecentFiles(object):
gfile = Gio.File.new_for_path(recent_path)
if len(uris) > 1:
- display_name = " : ".join(meld.misc.shorten_names(*uris))
+ display_name = " : ".join(meld.misc.shorten_names(*names))
else:
- display_path = uris[0]
+ display_path = names[0]
userhome = os.path.expanduser("~")
if display_path.startswith(userhome):
# FIXME: What should we show on Windows?
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]