diff options
author | monsta <[email protected]> | 2015-07-14 13:14:41 +0300 |
---|---|---|
committer | monsta <[email protected]> | 2015-07-14 13:14:41 +0300 |
commit | 4968f9a9dea791db8a06baababe764d8ad0ba6f6 (patch) | |
tree | 3369b7c7344bc40597e3950dc6f4152d5bc8b159 /plugins | |
parent | e75584f2e6169bbae2282b6ea7f18c0ad4072fb9 (diff) | |
download | pluma-4968f9a9dea791db8a06baababe764d8ad0ba6f6.tar.bz2 pluma-4968f9a9dea791db8a06baababe764d8ad0ba6f6.tar.xz |
quickopen plugin: remove wrong version check inherited from gedit
this should make quickopen dialog (Ctrl-Alt-O) recognize the files
from the currently selected dir in filebrowser plugin.
Diffstat (limited to 'plugins')
-rwxr-xr-x | plugins/quickopen/quickopen/windowhelper.py | 23 |
1 files changed, 11 insertions, 12 deletions
diff --git a/plugins/quickopen/quickopen/windowhelper.py b/plugins/quickopen/quickopen/windowhelper.py index dd1f8e90..57ec414f 100755 --- a/plugins/quickopen/quickopen/windowhelper.py +++ b/plugins/quickopen/quickopen/windowhelper.py @@ -88,23 +88,22 @@ class WindowHelper: paths.append(gfile.get_parent()) # File browser root directory - if pluma.version[0] > 2 or (pluma.version[0] == 2 and (pluma.version[1] > 26 or (pluma.version[1] == 26 and pluma.version[2] >= 2))): - bus = self._window.get_message_bus() + bus = self._window.get_message_bus() - try: - msg = bus.send_sync('/plugins/filebrowser', 'get_root') + try: + msg = bus.send_sync('/plugins/filebrowser', 'get_root') - if msg: - uri = msg.get_value('uri') + if msg: + uri = msg.get_value('uri') - if uri: - gfile = gio.File(uri) + if uri: + gfile = gio.File(uri) - if gfile.is_native(): - paths.append(gfile) + if gfile.is_native(): + paths.append(gfile) - except StandardError: - pass + except StandardError: + pass # Recent documents paths.append(RecentDocumentsDirectory(screen=self._window.get_screen())) |