trace.h
 1  #pragma once
 2  
 3  #include "State.h"
 4  
 5  #include <common/Telemetry/TraceBase.h>
 6  
 7  class Trace : public telemetry::TraceBase
 8  {
 9  public:
10      // Log if a key to key remap has been invoked today.
11      static void DailyKeyToKeyRemapInvoked() noexcept;
12  
13      // Log if a key to shortcut remap has been invoked today.
14      static void DailyKeyToShortcutRemapInvoked() noexcept;
15  
16      // Log if a shortcut to key remap has been invoked today.
17      static void DailyShortcutToKeyRemapInvoked() noexcept;
18  
19      // Log if a shortcut to shortcut remap has been invoked today.
20      static void DailyShortcutToShortcutRemapInvoked() noexcept;
21  
22      // Log if an app specific shortcut to key remap has been invoked today.
23      static void DailyAppSpecificShortcutToKeyRemapInvoked() noexcept;
24  
25      // Log if an app specific shortcut to shortcut remap has been invoked today.
26      static void DailyAppSpecificShortcutToShortcutRemapInvoked() noexcept;
27  
28      // Log if a key remap has been invoked (not being used currently, due to being garrulous)
29      static void KeyRemapInvoked(bool isKeyToKey) noexcept;
30  
31      // Log if a shortcut remap has been invoked (not being used currently, due to being garrulous)
32      static void ShortcutRemapInvoked(bool isShortcutToShortcut, bool isAppSpecific) noexcept;
33  
34      // Log the current remappings of key and shortcuts when keyboard manager engine loads the settings.
35      static void SendKeyAndShortcutRemapLoadedConfiguration(State& remappings) noexcept;
36  
37      // Log an error while trying to send remappings telemetry.
38      static void ErrorSendingKeyAndShortcutRemapLoadedConfiguration() noexcept;
39  
40      // Log if an error occurs in KBM
41      static void Error(const DWORD errorCode, std::wstring errorMessage, std::wstring methodName) noexcept;
42  };