mirror of
https://github.com/microsoft/PowerToys.git
synced 2026-04-05 02:36:19 +02:00
Telemetry events
* Don't trace event on exit change 'PowertoyModuleDeleter' to not call 'module->disable();' before 'module->destroy();' so the module can distinguish between being turned off and PowerToys exiting. Code formatting. * uppercase for event name * Trace on/off event for ShortcutGuide module * Trace the 'hide' event only if the guide was visible 'on_hide()' is invoked when the module is turned off, in that case don't trace the hide event. * Remove spaces in data field names Remove 'ShowGuide' event since it's not providing any useful data. * Include build number in version number
This commit is contained in:
@@ -240,7 +240,6 @@ void D2DOverlayWindow::show(HWND active_window) {
|
||||
tasklist_cv_mutex.unlock();
|
||||
tasklist_cv.notify_one();
|
||||
}
|
||||
Trace::EventShow();
|
||||
}
|
||||
|
||||
void D2DOverlayWindow::animate(int vk_code) {
|
||||
@@ -350,7 +349,11 @@ void D2DOverlayWindow::on_hide() {
|
||||
DwmUnregisterThumbnail(thumbnail);
|
||||
}
|
||||
std::chrono::steady_clock::time_point shown_end_time = std::chrono::steady_clock::now();
|
||||
Trace::EventHide(std::chrono::duration_cast<std::chrono::milliseconds>(shown_end_time - shown_start_time).count(), key_pressed);
|
||||
// Trace the event only if the overaly window was visible.
|
||||
if (shown_start_time.time_since_epoch().count() > 0) {
|
||||
Trace::EventHide(std::chrono::duration_cast<std::chrono::milliseconds>(shown_end_time - shown_start_time).count(), key_pressed);
|
||||
shown_start_time = {};
|
||||
}
|
||||
key_pressed.clear();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user