From 045a74c7b4bb6e3a0a15c4bb8ad95c3a9699d56a Mon Sep 17 00:00:00 2001 From: Denis Fomin Date: Tue, 2 Nov 2010 15:36:29 +0300 Subject: [PATCH] whiteboard plugin. Ability to save images --- plugins/whiteboard/whiteboard_widget.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/plugins/whiteboard/whiteboard_widget.py b/plugins/whiteboard/whiteboard_widget.py index 30b00dfd3..a3f756fa6 100644 --- a/plugins/whiteboard/whiteboard_widget.py +++ b/plugins/whiteboard/whiteboard_widget.py @@ -108,7 +108,7 @@ class Whiteboard(object): self.image.clear_canvas() def on_export_button_clicked(self, widget): - self.image.export_svg(filename) + SvgChooserDialog(self.image.export_svg) def on_fg_color_button_color_set(self, widget): self.color = str(self.fg_color_select_button.get_color()) @@ -258,8 +258,8 @@ class SvgChooserDialog(FileChooserDialog): path_to_clientcert_file = \ gtkgui_helpers.decode_filechooser_file_paths( (path_to_clientcert_file,))[0] - if os.path.exists(path_to_clientcert_file): - callback(widget, path_to_clientcert_file) + widget.destroy() + callback(path_to_clientcert_file) FileChooserDialog.__init__(self, title_text=_('Save Image as...'),