[PTRun]Add hotkey to the show telemetry event (#36869)

This commit is contained in:
Jaime Bernardo 2025-01-16 20:54:23 +00:00 коммит произвёл GitHub
Родитель 21fd5092b3
Коммит 41803cc632
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: B5690EEEBB952194
2 изменённых файлов: 8 добавлений и 1 удалений

Просмотреть файл

@ -12,6 +12,13 @@ namespace Microsoft.PowerLauncher.Telemetry
[EventData] [EventData]
public class LauncherShowEvent : EventBase, IEvent public class LauncherShowEvent : EventBase, IEvent
{ {
public LauncherShowEvent(string hotkey)
{
Hotkey = hotkey;
}
public string Hotkey { get; private set; }
public PartA_PrivTags PartA_PrivTags => PartA_PrivTags.ProductAndServiceUsage; public PartA_PrivTags PartA_PrivTags => PartA_PrivTags.ProductAndServiceUsage;
} }
} }

Просмотреть файл

@ -466,7 +466,7 @@ namespace PowerLauncher.ViewModel
// Don't trigger telemetry on cold boot. Must have been loaded at least once. // Don't trigger telemetry on cold boot. Must have been loaded at least once.
if (value == Visibility.Visible) if (value == Visibility.Visible)
{ {
PowerToysTelemetry.Log.WriteEvent(new LauncherShowEvent()); PowerToysTelemetry.Log.WriteEvent(new LauncherShowEvent(_settings.Hotkey));
} }
else else
{ {