mirror of
https://github.com/microsoft/terminal.git
synced 2025-12-11 04:38:24 -06:00
Move adjustProcessPriorityThrottled ctor earlier (#19283)
Test Impact: The LocalTests do not call `Initialize(HWND)`, so we would fail on launch. Also, we have `Create()` and `Initialize()` and `event Initialized` (the last of which is not called from either of the first two...)
This commit is contained in:
parent
a9b660cc36
commit
9e10436a80
@ -220,16 +220,6 @@ namespace winrt::TerminalApp::implementation
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
_adjustProcessPriorityThrottled = std::make_shared<ThrottledFunc<>>(
|
|
||||||
DispatcherQueue::GetForCurrentThread(),
|
|
||||||
til::throttled_func_options{
|
|
||||||
.delay = std::chrono::milliseconds{ 100 },
|
|
||||||
.debounce = true,
|
|
||||||
.trailing = true,
|
|
||||||
},
|
|
||||||
[=]() {
|
|
||||||
_adjustProcessPriority();
|
|
||||||
});
|
|
||||||
_hostingHwnd = hwnd;
|
_hostingHwnd = hwnd;
|
||||||
return S_OK;
|
return S_OK;
|
||||||
}
|
}
|
||||||
@ -410,6 +400,17 @@ namespace winrt::TerminalApp::implementation
|
|||||||
// them.
|
// them.
|
||||||
|
|
||||||
_tabRow.ShowElevationShield(IsRunningElevated() && _settings.GlobalSettings().ShowAdminShield());
|
_tabRow.ShowElevationShield(IsRunningElevated() && _settings.GlobalSettings().ShowAdminShield());
|
||||||
|
|
||||||
|
_adjustProcessPriorityThrottled = std::make_shared<ThrottledFunc<>>(
|
||||||
|
DispatcherQueue::GetForCurrentThread(),
|
||||||
|
til::throttled_func_options{
|
||||||
|
.delay = std::chrono::milliseconds{ 100 },
|
||||||
|
.debounce = true,
|
||||||
|
.trailing = true,
|
||||||
|
},
|
||||||
|
[=]() {
|
||||||
|
_adjustProcessPriority();
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
Windows::UI::Xaml::Automation::Peers::AutomationPeer TerminalPage::OnCreateAutomationPeer()
|
Windows::UI::Xaml::Automation::Peers::AutomationPeer TerminalPage::OnCreateAutomationPeer()
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user