Code

move undo commits closer to the UI
authorbuliabyak <buliabyak@users.sourceforge.net>
Sat, 5 Jul 2008 22:14:22 +0000 (22:14 +0000)
committerbuliabyak <buliabyak@users.sourceforge.net>
Sat, 5 Jul 2008 22:14:22 +0000 (22:14 +0000)
src/live_effects/effect.cpp
src/live_effects/parameter/path.cpp
src/ui/dialog/livepatheffect-editor.cpp

index 3848730187dc9cc2ff79d306fb278c0640ca9ae8..339e5c83385bd29942cfd57fd622869f812f6b51 100644 (file)
@@ -197,9 +197,6 @@ Effect::createAndApply(const char* name, SPDocument *doc, SPItem *item)
     gchar *href = g_strdup_printf("#%s", repr_id);
     sp_lpe_item_add_path_effect(SP_LPE_ITEM(item), href, true);
     g_free(href);
-
-    sp_document_done(doc, SP_VERB_DIALOG_LIVE_PATH_EFFECT,
-                     _("Create and apply path effect"));
 }
 
 void
index 16e579d16317e1968c856b0ba28a0cb95594609f..0f6a82971af0e9db0b30201305e0bf5ffe629079 100644 (file)
@@ -356,8 +356,6 @@ PathParam::paste_param_path(const char *svgd)
 
     param_write_to_repr(svgd);
     signal_path_pasted.emit();
-    sp_document_done(param_effect->getSPDoc(), SP_VERB_DIALOG_LIVE_PATH_EFFECT, 
-                     _("Paste path parameter"));
 }
 
 void
@@ -366,6 +364,8 @@ PathParam::on_paste_button_click()
     Inkscape::UI::ClipboardManager *cm = Inkscape::UI::ClipboardManager::get();
     Glib::ustring svgd = cm->getPathParameter();
     paste_param_path(svgd.data());
+    sp_document_done(param_effect->getSPDoc(), SP_VERB_DIALOG_LIVE_PATH_EFFECT, 
+                     _("Paste path parameter"));
 }
 
 void
index c1bbaa022c503118a81db3c6f743af42f0f95cd4..abf79d98dba8daeedfdf402ae76263e3f3394cc6 100644 (file)
@@ -331,6 +331,9 @@ LivePathEffectEditor::onApply()
 
             LivePathEffect::Effect::createAndApply(data->key.c_str(), doc, item);
 
+            sp_document_done(doc, SP_VERB_DIALOG_LIVE_PATH_EFFECT,
+                     _("Create and apply path effect"));
+
             onSelectionChanged(sel);
         }
     }