diff options
author | Sebastian Koslowski <koslowski@kit.edu> | 2016-07-12 15:12:57 +0200 |
---|---|---|
committer | Sebastian Koslowski <koslowski@kit.edu> | 2016-07-13 16:35:50 +0200 |
commit | 71cd4f066c079ad530d80afd263bb3cc8ec58b33 (patch) | |
tree | d9789a5223bd7dbca7dc671ca3b018a6a531bfae | |
parent | af615e894d6b339bda1ef3d5b1527d18e11ad231 (diff) |
grc: gtk3: quick fix for file dialogs
-rw-r--r-- | grc/gui/ActionHandler.py | 5 | ||||
-rw-r--r-- | grc/gui/FileDialogs.py | 2 |
2 files changed, 1 insertions, 6 deletions
diff --git a/grc/gui/ActionHandler.py b/grc/gui/ActionHandler.py index 16fed00db5..923d8d6d9a 100644 --- a/grc/gui/ActionHandler.py +++ b/grc/gui/ActionHandler.py @@ -511,9 +511,6 @@ class ActionHandler: flow_graph._options_block.get_param('generate_options').set_value(args[0]) flow_graph_update() elif action == Actions.FLOW_GRAPH_OPEN: - # TODO: Disable opening the flowgraph - pass - ''' file_paths = args if args else OpenFlowGraphFileDialog(page.file_path).run() if file_paths: # Open a new page for each file, show only the first for i,file_path in enumerate(file_paths): @@ -521,8 +518,6 @@ class ActionHandler: Preferences.add_recent_file(file_path) main.tool_bar.refresh_submenus() main.menu_bar.refresh_submenus() - main.vars.update_gui() - ''' elif action == Actions.FLOW_GRAPH_OPEN_QSS_THEME: file_paths = OpenQSSFileDialog(self.platform.config.install_prefix + '/share/gnuradio/themes/').run() diff --git a/grc/gui/FileDialogs.py b/grc/gui/FileDialogs.py index c7336a6c04..23fd7e7900 100644 --- a/grc/gui/FileDialogs.py +++ b/grc/gui/FileDialogs.py @@ -95,7 +95,7 @@ class FileDialogHelper(Gtk.FileChooserDialog): title: the title of the dialog (string) """ ok_stock = {Gtk.FileChooserAction.OPEN : 'gtk-open', Gtk.FileChooserAction.SAVE : 'gtk-save'}[action] - GObject.GObject.__init__(self, title, None, action, ('gtk-cancel', Gtk.ResponseType.CANCEL, ok_stock, Gtk.ResponseType.OK)) + Gtk.FileChooserDialog.__init__(self, title, None, action, ('gtk-cancel', Gtk.ResponseType.CANCEL, ok_stock, Gtk.ResponseType.OK)) self.set_select_multiple(False) self.set_local_only(True) self.add_filter(get_all_files_filter()) |