Ejemplo n.º 1
0
    def open_file(self, file_view, path, column, window):
        model = file_view.get_model()
        try:
            iter_ = model.get_iter(path)
        except ValueError:
            pass
        else:
            location = model.get_value(iter_, Column.LOCATION)
            Pluma.commands_load_uri(window, location.get_uri(), None, -1)

            self.destroy()
Ejemplo n.º 2
0
 def on_activated(self, gfile):
     Pluma.commands_load_uri(self._window, gfile.get_uri(), None, -1)
     return True
Ejemplo n.º 3
0
 def restore_open_files(self, window):
     if self.is_only_window():
         settings = Gio.Settings.new(SCHEMA_ID)
         for uri in settings.get_value('uris'):
             if Pluma.utils_uri_exists(uri):
                 Pluma.commands_load_uri(window, uri, None, -1)