mirror of
https://github.com/microsoft/PowerToys.git
synced 2024-12-03 19:39:07 +08:00
[Installer] add priority settings to the task scheduler PT task. (#27058)
* Installer: add priority settings to the task scheduler PT task. * Add priority settings for task creation (for Task Scheduler) to the runner as well * Modifying priority value
This commit is contained in:
parent
148f1df56c
commit
03a5a4200e
@ -389,6 +389,8 @@ UINT __stdcall CreateScheduledTaskCA(MSIHANDLE hInstall)
|
||||
ExitOnFailure(hr, "Cannot put_ExecutionTimeLimit setting info: %x", hr);
|
||||
hr = pSettings->put_DisallowStartIfOnBatteries(VARIANT_FALSE);
|
||||
ExitOnFailure(hr, "Cannot put_DisallowStartIfOnBatteries setting info: %x", hr);
|
||||
hr = pSettings->put_Priority(4);
|
||||
ExitOnFailure(hr, "Cannot put_Priority setting info : %x", hr);
|
||||
|
||||
// ------------------------------------------------------
|
||||
// Get the trigger collection to insert the logon trigger.
|
||||
|
@ -140,6 +140,8 @@ bool create_auto_start_task_for_this_user(bool runElevated)
|
||||
ExitOnFailure(hr, "Cannot put_ExecutionTimeLimit setting info: %x", hr);
|
||||
hr = pSettings->put_DisallowStartIfOnBatteries(VARIANT_FALSE);
|
||||
ExitOnFailure(hr, "Cannot put_DisallowStartIfOnBatteries setting info: %x", hr);
|
||||
hr = pSettings->put_Priority(4);
|
||||
ExitOnFailure(hr, "Cannot put_Priority setting info : %x", hr);
|
||||
|
||||
// ------------------------------------------------------
|
||||
// Get the trigger collection to insert the logon trigger.
|
||||
|
Loading…
Reference in New Issue
Block a user