summaryrefslogtreecommitdiffstats
path: root/src/extension/prefdialog.cpp
diff options
context:
space:
mode:
authorTed Gould <ted@gould.cx>2007-09-01 04:32:10 +0000
committergouldtj <gouldtj@users.sourceforge.net>2007-09-01 04:32:10 +0000
commitf512b9915196be7533eb6633504e2af73423bc15 (patch)
tree9ae83b84e925aab747be09c70392c305f03af3b0 /src/extension/prefdialog.cpp
parentr16339@tres: ted | 2007-08-19 19:47:57 -0700 (diff)
downloadinkscape-f512b9915196be7533eb6633504e2af73423bc15.tar.gz
inkscape-f512b9915196be7533eb6633504e2af73423bc15.zip
r16340@tres: ted | 2007-08-20 19:02:50 -0700
Pinned is still not working, somewhat usable state. Worth checking in. (bzr r3639)
Diffstat (limited to 'src/extension/prefdialog.cpp')
-rw-r--r--src/extension/prefdialog.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/extension/prefdialog.cpp b/src/extension/prefdialog.cpp
index eb6cbf6fa..62e6b9ff8 100644
--- a/src/extension/prefdialog.cpp
+++ b/src/extension/prefdialog.cpp
@@ -43,6 +43,7 @@ PrefDialog::PrefDialog (Glib::ustring name, gchar const * help, Gtk::Widget * co
_help(help),
_name(name),
_exEnv(exEnv),
+ _createdExEnv(false),
_button_ok(NULL),
_button_cancel(NULL),
_button_preview(NULL),
@@ -168,12 +169,26 @@ PrefDialog::pinned_toggle (void) {
_button_ok->set_label(Gtk::Stock::EXECUTE.id);
_button_cancel->set_label(Gtk::Stock::CLOSE.id);
+
+ if (_exEnv != NULL) {
+ _exEnv->shutdown();
+ if (_createdExEnv) {
+ delete _exEnv;
+ }
+ _exEnv = NULL;
+ }
} else {
_button_preview->set_sensitive(true);
set_modal(true);
_button_ok->set_label(Gtk::Stock::OK.id);
_button_cancel->set_label(Gtk::Stock::CANCEL.id);
+
+ if (_exEnv == NULL) {
+ _exEnv = new ExecutionEnv(_effect, SP_ACTIVE_DESKTOP, NULL, this);
+ _createdExEnv = true;
+ _exEnv->run();
+ }
}
}