mirror of
https://github.com/ayufan/steam-deck-tools.git
synced 2026-01-25 09:50:26 +01:00
PowerControl: Consider the foreground process to be holding profile configuration
This commit is contained in:
parent
2f2f17ad05
commit
7daa4ac27f
|
|
@ -32,6 +32,7 @@ namespace CommonHelpers
|
|||
public String ProcessName { get; set; }
|
||||
public uint LastFrame { get; set; }
|
||||
public DateTimeOffset LastFrameTime { get; set; }
|
||||
public bool IsOSDForeground { get; set; }
|
||||
|
||||
public bool IsRecent
|
||||
{
|
||||
|
|
@ -60,6 +61,8 @@ namespace CommonHelpers
|
|||
|
||||
var now = DateTimeOffset.UtcNow;
|
||||
|
||||
var topLevelProcessId = GetTopLevelProcessId();
|
||||
|
||||
foreach (var app in appEntries)
|
||||
{
|
||||
if (!oldIDs.TryGetValue(app.ProcessId, out var entry))
|
||||
|
|
@ -67,7 +70,9 @@ namespace CommonHelpers
|
|||
entry.ProcessName = Path.GetFileNameWithoutExtension(app.Name);
|
||||
}
|
||||
|
||||
if (entry.LastFrame != app.OSDFrameId)
|
||||
entry.IsOSDForeground = (topLevelProcessId == app.ProcessId);
|
||||
|
||||
if (entry.LastFrame != app.OSDFrameId || entry.IsOSDForeground)
|
||||
{
|
||||
entry.LastFrame = app.OSDFrameId;
|
||||
entry.LastFrameTime = now;
|
||||
|
|
|
|||
|
|
@ -9,6 +9,7 @@
|
|||
|
||||
## 0.6.x
|
||||
|
||||
- PowerControl: Consider the foreground process to be holding profile configuration as long as it is running
|
||||
- SteamController: Require administrator privileges
|
||||
- PowerControl: Apply profile changes with a delay in bulk
|
||||
- SteamController: Fix detection of the Steam client released around 2023-01-20, version: 1674182294
|
||||
|
|
|
|||
Loading…
Reference in a new issue