PowerToys/src/common/logger/logger_settings.h
Jaime Bernardo 2d5276f742
Mouse Utils - Mouse Highlighter (#14496)
* New PowerToys template

* Add CppWinRt to empty PowerToy

* Add Settings reference to empty PowerToy

* Use proper output dir

* Proper WindowsTargetPlatformVersion

* Add filters to vcxproj

* Proper resource file generation

* Add MouseHighlighter proof of concept code

* Abstract implementation into a struct

* Enable module

* Disable module

* Add enable module to settings page

* Can change the hotkey in settings

* Remove remaining boilerplate code

* Add logging

* Add telemetry

* Add Oobe entry

* Add installer instructions

* Add dll to pipelines

* fix spellchecker

* Add more configurability

* Make settings a bit prettier

* Fix spellchecker

* Fix wrong default fade timers

* Fix user facing strings

* Tweak default duration values

* Fix to appear in every virtual desktop

* [Mouse Highlighter] Show highlight on mouse drag (#14529)

* [Mouse Highlighter]show pointer on mouse drag

* fix spellchecker

* [MU] UI tweaks (#14544)

* UI tweaks

* Update Resources.resw

* Updated text strings

* fix spellcheck

Co-authored-by: Laute <Niels.Laute@philips.com>

* tweak default values

* PR feedback: use wstring_view

* PR feedback: Log error on json error

* PR feedback: don't throw 1

* PR feedback: fix copy-pasta leftColor->rightColor

* PR feedback:Add another error message on exception

* PR feedback: add todo to use commons/utils/json.h

Co-authored-by: Niels Laute <niels.laute@live.nl>
Co-authored-by: Laute <Niels.Laute@philips.com>
2021-11-22 13:31:31 +00:00

38 lines
2.2 KiB
C++

#pragma once
#include <string>
struct LogSettings
{
// The following strings are not localizable
inline const static std::wstring defaultLogLevel = L"trace";
inline const static std::wstring logLevelOption = L"logLevel";
inline const static std::string runnerLoggerName = "runner";
inline const static std::wstring logPath = L"Logs\\";
inline const static std::wstring runnerLogPath = L"RunnerLogs\\runner-log.txt";
inline const static std::string actionRunnerLoggerName = "action-runner";
inline const static std::wstring actionRunnerLogPath = L"RunnerLogs\\action-runner-log.txt";
inline const static std::string updateLoggerName = "update";
inline const static std::wstring updateLogPath = L"UpdateLogs\\update-log.txt";
inline const static std::string fileExplorerLoggerName = "FileExplorer";
inline const static std::wstring fileExplorerLogPath = L"Logs\\file-explorer-log.txt";
inline const static std::string launcherLoggerName = "launcher";
inline const static std::wstring launcherLogPath = L"LogsModuleInterface\\launcher-log.txt";
inline const static std::wstring awakeLogPath = L"Logs\\awake-log.txt";
inline const static std::string fancyZonesLoggerName = "fancyzones";
inline const static std::wstring fancyZonesLogPath = L"fancyzones-log.txt";
inline const static std::wstring fancyZonesOldLogPath = L"FancyZonesLogs\\"; // needed to clean up old logs
inline const static std::string shortcutGuideLoggerName = "shortcut-guide";
inline const static std::wstring shortcutGuideLogPath = L"ShortcutGuideLogs\\shortcut-guide-log.txt";
inline const static std::string keyboardManagerLoggerName = "keyboard-manager";
inline const static std::wstring keyboardManagerLogPath = L"Logs\\keyboard-manager-log.txt";
inline const static std::string findMyMouseLoggerName = "find-my-mouse";
inline const static std::string mouseHighlighterLoggerName = "mouse-highlighter";
inline const static std::string powerRenameLoggerName = "powerrename";
inline const static int retention = 30;
std::wstring logLevel;
LogSettings();
};
// Get log settings from file. File with default options is created if it does not exist
LogSettings get_log_settings(std::wstring_view file_name);