From: mental Date: Thu, 10 May 2007 01:18:56 +0000 (+0000) Subject: add document to action events X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=0e2a2cc7bb4f35dbc5150de387b2e651714b6d5b;p=inkscape.git add document to action events --- diff --git a/src/helper/action.cpp b/src/helper/action.cpp index d67bc5fc2..9b8cbfce8 100644 --- a/src/helper/action.cpp +++ b/src/helper/action.cpp @@ -17,6 +17,8 @@ #include "debug/timestamp.h" #include "debug/simple-event.h" #include "debug/event-tracker.h" +#include "ui/view/view.h" +#include "document.h" #include "helper/action.h" static void sp_action_class_init (SPActionClass *klass); @@ -129,6 +131,10 @@ public: : ActionEventBase(share_static_string("action")) { _addProperty(share_static_string("timestamp"), timestamp()); + SPDocument *document = action->view->doc(); + if (document) { + _addProperty(share_static_string("document"), document->serial()); + } _addProperty(share_static_string("verb"), action->id); } };