diff --git a/src/modules/videoconference/VideoConferenceModule/VideoConferenceModule.cpp b/src/modules/videoconference/VideoConferenceModule/VideoConferenceModule.cpp index fa692895f4..aab538e883 100644 --- a/src/modules/videoconference/VideoConferenceModule/VideoConferenceModule.cpp +++ b/src/modules/videoconference/VideoConferenceModule/VideoConferenceModule.cpp @@ -611,6 +611,7 @@ void VideoConferenceModule::enable() #endif hook_handle = SetWindowsHookEx(WH_KEYBOARD_LL, LowLevelKeyboardProc, GetModuleHandle(NULL), NULL); } + Trace::EnableVideoConference(true); } void VideoConferenceModule::unmuteAll() @@ -664,6 +665,7 @@ void VideoConferenceModule::disable() _enabled = false; } + Trace::EnableVideoConference(false); } bool VideoConferenceModule::is_enabled() diff --git a/src/modules/videoconference/VideoConferenceModule/trace.cpp b/src/modules/videoconference/VideoConferenceModule/trace.cpp index 377d49b18a..889cca2a15 100644 --- a/src/modules/videoconference/VideoConferenceModule/trace.cpp +++ b/src/modules/videoconference/VideoConferenceModule/trace.cpp @@ -19,6 +19,17 @@ void Trace::UnregisterProvider() noexcept TraceLoggingUnregister(g_hProvider); } +// Log if the user has VCM enabled or disabled +void Trace::EnableVideoConference(const bool enabled) noexcept +{ + TraceLoggingWrite( + g_hProvider, + "VideoConference_EnableVideoConference", + ProjectTelemetryPrivacyDataTag(ProjectTelemetryTag_ProductAndServicePerformance), + TraceLoggingKeyword(PROJECT_KEYWORD_MEASURE), + TraceLoggingBoolean(enabled, "Enabled")); +} + void Trace::SettingsChanged(const struct VideoConferenceSettings& settings) noexcept { bool CustomOverlayImage = (settings.imageOverlayPath.length() > 0); diff --git a/src/modules/videoconference/VideoConferenceModule/trace.h b/src/modules/videoconference/VideoConferenceModule/trace.h index c9283256df..5d42709be2 100644 --- a/src/modules/videoconference/VideoConferenceModule/trace.h +++ b/src/modules/videoconference/VideoConferenceModule/trace.h @@ -6,6 +6,7 @@ class Trace public: static void RegisterProvider() noexcept; static void UnregisterProvider() noexcept; + static void EnableVideoConference(const bool enabled) noexcept; static void SettingsChanged(const struct VideoConferenceSettings &settings) noexcept; static void MicrophoneMuted() noexcept; static void CameraMuted() noexcept;