[gedit-plugins] Use Gio.file_new_for_path



commit 5f3cc4b5983f7b729ac931ac33bd4e3efb820cb8
Author: Ignacio Casal Quinteiro <icq gnome org>
Date:   Thu Apr 7 13:47:34 2011 +0200

    Use Gio.file_new_for_path

 plugins/commander/modules/edit.py |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/plugins/commander/modules/edit.py b/plugins/commander/modules/edit.py
index 9ebf086..959692b 100644
--- a/plugins/commander/modules/edit.py
+++ b/plugins/commander/modules/edit.py
@@ -54,9 +54,9 @@ def __default__(filename, view):
 
     if matches:
         for match in matches:
-            files.append(Gio.File.new_for_path(match))
+            files.append(Gio.file_new_for_path(match))
     else:
-        files.append(Gio.File.new_for_path(filename))
+        files.append(Gio.file_new_for_path(filename))
 
     if files:
         window = view.get_toplevel()
@@ -91,7 +91,7 @@ def rename(view, newfile):
         raise commander.commands.exceptions.Execute('Current document file does not exist')
 
     if os.path.isabs(newfile):
-        dest = Gio.File.new_for_path(newfile)
+        dest = Gio.file_new_for_path(newfile)
     else:
         dest = f.get_parent().resolve_relative_path(newfile)
 
@@ -133,7 +133,7 @@ def _mod_has_alias(mod, alias):
 
 def _edit_command(view, mod, func=None):
     try:
-        location = Gio.File.new_for_path(inspect.getsourcefile(mod))
+        location = Gio.file_new_for_path(inspect.getsourcefile(mod))
     except:
         return False
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]