Code

improve get_nodetype angle checking, thanks nathan!
[inkscape.git] / src / helper / action.cpp
index d67bc5fc2a8e08d25caf0145e056371e8ff09141..84d150615388fcae9c58853087dd77c0543e1fe8 100644 (file)
@@ -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,12 @@ public:
     : ActionEventBase(share_static_string("action"))
     {
         _addProperty(share_static_string("timestamp"), timestamp());
+        if (action->view) {
+            SPDocument *document = action->view->doc();
+            if (document) {
+                _addProperty(share_static_string("document"), document->serial());
+            }
+        }
         _addProperty(share_static_string("verb"), action->id);
     }
 };