- QString anId = anAction->data().toString();
- QStringList message = (QStringList() << moduleName());
- if (anId.contains("Sketch"))
- message << tr("sketcher");
- message << tr("operation %1 has been activated").arg(anAction->text());
- CAM_Application::logUserEvent(message.join(": "));
+ const QString anId = anAction->data().toString();
+ const QString section = anId.contains("Sketch") ? "sketcher" : "";
+
+ CAM_Application::logStructuredUserEvent( moduleName(),
+ section,
+ anAction->text(),
+ "activated" );