Skip to content

Free, open-source Windows optimization tool for performance, privacy, and simplicity.

feat: add missing files

itsfatduck48c4231cc414
diff --git a/optimizerDuck/Core/Features/Gaming.cs b/optimizerDuck/Core/Features/Gaming.cs
new file mode 100644
index 0000000..25b46bc
--- /dev/null
+++ b/optimizerDuck/Core/Features/Gaming.cs
@@ -0,0 +1,221 @@
+using System.Collections.ObjectModel;
+using optimizerDuck.Core.Interfaces;
+using optimizerDuck.Core.Models.Attributes;
+using optimizerDuck.Core.Models.Features;
+using optimizerDuck.Core.Models.Optimization.Services;
+using optimizerDuck.Core.Models.UI;
+using optimizerDuck.Services.Managers;
+using optimizerDuck.Services.OptimizationServices;
+using optimizerDuck.UI.Views.Pages.Features;
+using Wpf.Ui.Controls;
+
+namespace optimizerDuck.Core.Features;
+
+[FeatureCategory(PageType = typeof(GamingFeatureCategory))]
+public class Gaming : IFeatureCategory
+{
+ private enum Sections
+ {
+ GameSettings,
+ Input,
+ Display
+ }
+
+ public string Name => Loc.Instance[$"Features.{nameof(Gaming)}.Name"];
+ public string Description => Loc.Instance[$"Features.{nameof(Gaming)}.Description"];
+ public SymbolRegular Icon { get; init; } = SymbolRegular.XboxController24;
+ public FeatureCategoryOrder Order { get; init; } = FeatureCategoryOrder.Gaming;
+ public ObservableCollection<IFeature> Features { get; init; } = [];
+
+ [Feature(Section = nameof(Sections.GameSettings), Icon = SymbolRegular.XboxController24)]
+ public class GameMode : BaseFeature
+ {
+ protected override IEnumerable<RegistryToggle> RegistryToggles =>
+ [
+ new()
+ {
+ Path = @"HKCU\Software\Microsoft\GameBar",
+ Name = "AllowAutoGameMode",
+ OnValue = 1,
+ OffValue = 0,
+ DefaultValue = 1
+ },
+ new()
+ {
+ Path = @"HKCU\Software\Microsoft\GameBar",
+ Name = "AutoGameModeEnabled",
+ OnValue = 1,
+ OffValue = 0,
+ DefaultValue = 1
+ }
+ ];
+ }
+
+ [Feature(Section = nameof(Sections.GameSettings), Icon = SymbolRegular.XboxConsole24)]
+ public class GameBar : BaseFeature
+ {
+ protected override IEnumerable<RegistryToggle> RegistryToggles =>
+ [
+ new()
+ {
+ Path = @"HKCU\System\GameConfigStore",
+ Name = "GameBarEnabled",
+ OnValue = 1,
+ OffValue = 0,
+ DefaultValue = 1
+ },
+ new()
+ {
+ Path = @"HKCU\Software\Microsoft\GameBar",
+ Name = "ShowStartupPanel",
+ OnValue = 1,
+ OffValue = 0,
+ DefaultValue = 1
+ },
+ new()
+ {
+ Path = @"HKCU\Software\Microsoft\GameBar",
+ Name = "UseNexusForGameBarEnabled",
+ OnValue = 1,
+ OffValue = 0,
+ DefaultValue = 1
+ },
+ new()
+ {
+ Path = @"HKCU\Software\Microsoft\GameBar",
+ Name = "GamePanelStartupTipIndex",
+ OnValue = 3,
+ OffValue = 0,
+ DefaultValue = 3
+ }
+ ];
+ }
+
+ [Feature(Section = nameof(Sections.GameSettings), Icon = SymbolRegular.Record24)]
+ public class BackgroundRecording : BaseFeature
+ {
+ protected override IEnumerable<RegistryToggle> RegistryToggles =>
+ [
+ new()
+ {
+ Path = @"HKCU\Software\Microsoft\Windows\CurrentVersion\GameDVR",
+ Name = "AppCaptureEnabled",
+ OnValue = 1,
+ OffValue = 0,
+ DefaultValue = 1
+ },
+ new()
+ {
+ Path = @"HKCU\System\GameConfigStore",
+ Name = "GameDVR_Enabled",
+ OnValue = 1,
+ OffValue = 0,
+ DefaultValue = 1
+ },
+ new()
+ {
+ Path = @"HKLM\SOFTWARE\Policies\Microsoft\Windows\GameDVR",
+ Name = "AllowGameDVR",
+ OnValue = 1,
+ OffValue = 0,
+ DefaultValue = 1
+ },
+ new()
+ {
+ Path = @"HKLM\SOFTWARE\Microsoft\PolicyManager\default\ApplicationManagement\AllowGameDVR",
+ Name = "value",
+ OnValue = 1,
+ OffValue = 0,
+ DefaultValue = 1
+ }
+ ];
+ }
+
+ [Feature(Section = nameof(Sections.Input), Icon = SymbolRegular.Cursor24)]
+ public class MouseAcceleration : BaseFeature
+ {
+ protected override IEnumerable<RegistryToggle> RegistryToggles =>
+ [
+ new()
+ {
+ Path = @"HKCU\Control Panel\Mouse",
+ Name = "MouseSpeed",
+ OnValue = "1",
+ OffValue = "0",
+ DefaultValue = "1"
+ },
+ new()
+ {
+ Path = @"HKCU\Control Panel\Mouse",
+ Name = "MouseThreshold1",
+ OnValue = "6",
+ OffValue = "0",
+ DefaultValue = "6"
+ },
+ new()
+ {
+ Path = @"HKCU\Control Panel\Mouse",
+ Name = "MouseThreshold2",
+ OnValue = "10",
+ OffValue = "0",
+ DefaultValue = "10"
+ }
+ ];
+ }
+
+ [Feature(Section = nameof(Sections.Display), Icon = SymbolRegular.FullScreenMaximize24)]
+ public class FullscreenOptimizations : BaseFeature
+ {
+ protected override IEnumerable<RegistryToggle> RegistryToggles =>
+ [
+ new()
+ {
+ Path = @"HKCU\System\GameConfigStore",
+ Name = "GameDVR_DXGIHonorFSEWindowsCompatible",
+ OnValue = 0,
+ OffValue = 1,
+ DefaultValue = 0
+ },
+ new()
+ {
+ Path = @"HKCU\System\GameConfigStore",
+ Name = "GameDVR_FSEBehavior",
+ OnValue = 0,
+ OffValue = 2,
+ DefaultValue = 0
+ },
+ new()
+ {
+ Path = @"HKCU\System\GameConfigStore",
+ Name = "GameDVR_FSEBehaviorMode",
+ OnValue = 0,
+ OffValue = 2,
+ DefaultValue = 0
+ },
+ new()
+ {
+ Path = @"HKCU\System\GameConfigStore",
+ Name = "GameDVR_HonorUserFSEBehaviorMode",
+ OnValue = 0,
+ OffValue = 1,
+ DefaultValue = 0
+ }
+ ];
+ }
+
+ [Feature(Section = nameof(Sections.Display), Icon = SymbolRegular.VideoClip24)]
+ public class HardwareAcceleratedGpuScheduling : BaseFeature
+ {
+ protected override IEnumerable<RegistryToggle> RegistryToggles =>
+ [
+ new()
+ {
+ Path = @"HKLM\SYSTEM\CurrentControlSet\Control\GraphicsDrivers",
+ Name = "HwSchMode",
+ OnValue = 2,
+ OffValue = 1,
+ DefaultValue = 1
+ }
+ ];
+ }
+}
diff --git a/optimizerDuck/Core/Optimizers/UserExperience.cs b/optimizerDuck/Core/Optimizers/UserExperience.cs
index 6ee267d..86c2273 100644
--- a/optimizerDuck/Core/Optimizers/UserExperience.cs
+++ b/optimizerDuck/Core/Optimizers/UserExperience.cs
@@ -18,191 +18,6 @@ public class UserExperience : IOptimizationCategory
public OptimizationCategoryOrder Order { get; init; } = OptimizationCategoryOrder.UserExperience;
public ObservableCollection<IOptimization> Optimizations { get; init; } = [];
- [Optimization(
- Id = "B4E0B6C1-7A1C-4A92-8D38-9B8E5F2D8D11",
- Risk = OptimizationRisk.Safe,
- Tags = OptimizationTags.System | OptimizationTags.Visual | OptimizationTags.Privacy)]
- public sealed class DisableTaskbarNewsAndInterests : BaseOptimization
- {
- public override Task<ApplyResult> ApplyAsync(IProgress<ProcessingProgress> progress,
- OptimizationContext context)
- {
- RegistryService.Write(
- new RegistryItem(@"HKLM\SOFTWARE\Policies\Microsoft\Dsh", "AllowNewsAndInterests", 0),
- new RegistryItem(@"HKLM\SOFTWARE\Policies\Microsoft\Windows\Windows Feeds", "EnableFeeds", 0)
- );
- context.Logger.LogInformation("Disabled taskbar news and interests");
- return Task.FromResult(ApplyResult.True());
- }
- }
-
- [Optimization(
- Id = "2F8E9B9A-31D5-4B4D-BE47-6F3E9C90A7C3",
- Risk = OptimizationRisk.Safe,
- Tags = OptimizationTags.System | OptimizationTags.Visual)]
- public sealed class DisableTaskbarExtraButtons : BaseOptimization
- {
- public override Task<ApplyResult> ApplyAsync(IProgress<ProcessingProgress> progress,
- OptimizationContext context)
- {
- RegistryService.Write(
- new RegistryItem(@"HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced",
- "TaskbarMn", 0), // Chat
- new RegistryItem(@"HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced",
- "ShowTaskViewButton", 0)
- );
- context.Logger.LogInformation("Disabled extra taskbar buttons");
- return Task.FromResult(ApplyResult.True());
- }
- }
-
- [Optimization(
- Id = "8C9F43B4-5C5D-4F71-9E4E-1C7E9B4E6D90",
- Risk = OptimizationRisk.Safe,
- Tags = OptimizationTags.System | OptimizationTags.Visual | OptimizationTags.Privacy)]
- public sealed class DisableTaskbarSearchAndBing : BaseOptimization
- {
- public override Task<ApplyResult> ApplyAsync(IProgress<ProcessingProgress> progress,
- OptimizationContext context)
- {
- RegistryService.Write(
- new RegistryItem(@"HKCU\Software\Microsoft\Windows\CurrentVersion\Search",
- "SearchboxTaskbarMode", 0),
- new RegistryItem(@"HKCU\Software\Microsoft\Windows\CurrentVersion\Search",
- "BingSearchEnabled", 0)
- );
- context.Logger.LogInformation("Disabled taskbar search and Bing");
- return Task.FromResult(ApplyResult.True());
- }
- }
-
- [Optimization(
- Id = "4A1F6B78-4E5E-4A77-A5C9-7C6F3D2E1B90",
- Risk = OptimizationRisk.Safe,
- Tags = OptimizationTags.System)]
- public sealed class RemoveMeetNowAndPeople : BaseOptimization
- {
- public override Task<ApplyResult> ApplyAsync(IProgress<ProcessingProgress> progress,
- OptimizationContext context)
- {
- RegistryService.Write(
- new RegistryItem(@"HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer",
- "HideSCAMeetNow", 1),
- new RegistryItem(@"HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced\People",
- "PeopleBand", 0)
- );
- context.Logger.LogInformation("Removed Meet Now and People icons");
- return Task.FromResult(ApplyResult.True());
- }
- }
-
- [Optimization(
- Id = "E1C2D3A4-B5F6-47A8-9C0D-1F2E3A4B5C6D",
- Risk = OptimizationRisk.Safe,
- Tags = OptimizationTags.System)]
- public sealed class EnableTaskbarEndTask : BaseOptimization
- {
- public override Task<ApplyResult> ApplyAsync(IProgress<ProcessingProgress> progress,
- OptimizationContext context)
- {
- RegistryService.Write(
- new RegistryItem(
- @"HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced\TaskbarDeveloperSettings",
- "TaskbarEndTask", 1)
- );
- context.Logger.LogInformation("Enabled taskbar end task feature");
- return Task.FromResult(ApplyResult.True());
- }
- }
-
- [Optimization(
- Id = "C08A5C23-6977-4C14-8CB2-F398CD85B3EE",
- Risk = OptimizationRisk.Safe,
- Tags = OptimizationTags.System | OptimizationTags.Visual | OptimizationTags.Power)]
- public sealed class EnableDarkMode : BaseOptimization
- {
- public override Task<ApplyResult> ApplyAsync(IProgress<ProcessingProgress> progress,
- OptimizationContext context)
- {
- RegistryService.Write(
- new RegistryItem(@"HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Themes\Personalize",
- "AppsUseLightTheme", 0),
- new RegistryItem(@"HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Themes\Personalize",
- "SystemUsesLightTheme", 0)
- );
- context.Logger.LogInformation("Enabled dark mode");
- return Task.FromResult(ApplyResult.True());
- }
- }
-
- [Optimization(
- Id = "5A6E2C9D-3F7E-4B92-A9D1-7F3C2A6E8813",
- Risk = OptimizationRisk.Safe,
- Tags = OptimizationTags.System | OptimizationTags.Privacy)]
- public sealed class DisableExplorerAndSystemNotifications : BaseOptimization
- {
- public override Task<ApplyResult> ApplyAsync(IProgress<ProcessingProgress> progress,
- OptimizationContext context)
- {
- RegistryService.Write(
- new RegistryItem(@"HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced",
- "ShowSyncProviderNotifications", 0),
- new RegistryItem(@"HKCU\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager",
- "SystemPaneSuggestionsEnabled", 0),
- new RegistryItem(@"HKCU\Software\Microsoft\Windows\CurrentVersion\PushNotifications",
- "ToastEnabled", 0),
- new RegistryItem(@"HKCU\Software\Microsoft\Windows\CurrentVersion\PushNotifications",
- "LockScreenToastEnabled", 0)
- );
- context.Logger.LogInformation("Disabled Explorer and system notifications");
- return Task.FromResult(ApplyResult.True());
- }
- }
-
- [Optimization(
- Id = "B9D2F8A7-1A52-4E73-8E19-92C3A6E7D0C2",
- Risk = OptimizationRisk.Safe,
- Tags = OptimizationTags.System | OptimizationTags.Visual)]
- public sealed class ShowFileExtensionsAndHiddenFiles : BaseOptimization
- {
- public override Task<ApplyResult> ApplyAsync(IProgress<ProcessingProgress> progress,
- OptimizationContext context)
- {
- RegistryService.Write(
- new RegistryItem(
- @"HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced",
- "HideFileExt", 0)
- );
- RegistryService.Write(
- new RegistryItem(
- @"HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced",
- "Hidden", 1)
- );
- context.Logger.LogInformation("Showed file extensions and hidden files");
- return Task.FromResult(ApplyResult.True());
- }
- }
-
- [Optimization(
- Id = "1A4D9E7F-9B73-4A0E-B5C2-7D9F1E6C4A55",
- Risk = OptimizationRisk.Safe,
- Tags = OptimizationTags.Visual)]
- public sealed class EnableClassicContextMenu : BaseOptimization
- {
- public override Task<ApplyResult> ApplyAsync(IProgress<ProcessingProgress> progress,
- OptimizationContext context)
- {
- RegistryService.Write(
- new RegistryItem(
- @"HKCU\SOFTWARE\Classes\CLSID\{86ca1aa0-34aa-4e8b-a509-50c905bae2a2}\InprocServer32",
- "",
- "")
- );
- context.Logger.LogInformation("Enabled classic context menu");
- return Task.FromResult(ApplyResult.True());
- }
- }
-
[Optimization(
Id = "9E2C4F7D-5A6B-4E9D-8C71-6E2F5A9C3314",
Risk = OptimizationRisk.Safe,
@@ -222,47 +37,4 @@ public class UserExperience : IOptimizationCategory
return Task.FromResult(ApplyResult.True());
}
}
-
- [Optimization(
- Id = "C7A98B41-0F1E-4E0D-8D4F-5A7F2E3D9B66",
- Risk = OptimizationRisk.Safe,
- Tags = OptimizationTags.Visual)]
- public sealed class ShowSecondsInSystemClock : BaseOptimization
- {
- public override Task<ApplyResult> ApplyAsync(IProgress<ProcessingProgress> progress,
- OptimizationContext context)
- {
- RegistryService.Write(
- new RegistryItem(
- @"HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced",
- "ShowSecondsInSystemClock", 1)
- );
- context.Logger.LogInformation("Showed seconds in system clock");
- return Task.FromResult(ApplyResult.True());
- }
- }
-
- [Optimization(
- Id = "7D9A4C3E-6F1B-4E8C-A9F2-3D7E5C6A8815",
- Risk = OptimizationRisk.Safe,
- Tags = OptimizationTags.System | OptimizationTags.Visual | OptimizationTags.Performance)]
- public sealed class DisableVisualEffects : BaseOptimization
- {
- public override Task<ApplyResult> ApplyAsync(IProgress<ProcessingProgress> progress,
- OptimizationContext context)
- {
- RegistryService.Write(
- new RegistryItem(@"HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced",
- "TaskbarAnimations", 0),
- new RegistryItem(@"HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced",
- "ListviewShadow", 0),
- new RegistryItem(@"HKCU\Software\Microsoft\Windows\CurrentVersion\Themes\Personalize",
- "EnableTransparency", 0),
- new RegistryItem(@"HKCU\Software\Microsoft\Windows\DWM",
- "EnableAeroPeek", 0)
- );
- context.Logger.LogInformation("Disabled visual effects");
- return Task.FromResult(ApplyResult.True());
- }
- }
}
\ No newline at end of file