Skip to content

Commit

Permalink
Reduce CPU usage
Browse files Browse the repository at this point in the history
  • Loading branch information
timokoessler committed Jan 29, 2025
1 parent cf0a72b commit 57085ba
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions Guard.WPF/Views/Pages/Home.xaml.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
using System.Windows;
using System.Windows.Controls;
using System.Windows.Media.Animation;
using Guard.Core.Models;
using Guard.Core.Storage;
using Guard.WPF.Core;
Expand Down Expand Up @@ -55,6 +56,12 @@ public Home()
}
}
};

// Update the FPS of the animations to reduce CPU usage
Timeline.DesiredFrameRateProperty.OverrideMetadata(
typeof(Timeline),
new FrameworkPropertyMetadata { DefaultValue = 20 }
);
}

private async void LoadTokens()
Expand Down

0 comments on commit 57085ba

Please sign in to comment.