mirror of
https://github.com/microsoft/PowerToys.git
synced 2026-04-07 19:57:07 +02:00
[fxcop] Settings UI library (part 2) (#7257)
* Suppress warnings for read-only collection properties (see code comments) * Call ConfigureAwait on tasks * Add CultureInfo and StringComparison policy for certain string operations * Add checks and exceptions for null arguments to public methods * Rename RaisePropertyChanged to NotifyPropertyChanged * Suppress CA1000 warning on SettingsRepository class * Implement Disposable pattern in HotkeySettingsControlHook * Modify null argument handling in KeyboardManagerViewModel::CombineShortcutLists
This commit is contained in:
@@ -79,15 +79,15 @@ namespace Microsoft.PowerToys.Settings.UI.Views
|
||||
|
||||
public int UpdateUIThemeMethod(string themeName)
|
||||
{
|
||||
switch (themeName)
|
||||
switch (themeName.ToUpperInvariant())
|
||||
{
|
||||
case "light":
|
||||
case "LIGHT":
|
||||
ShellPage.ShellHandler.RequestedTheme = ElementTheme.Light;
|
||||
break;
|
||||
case "dark":
|
||||
case "DARK":
|
||||
ShellPage.ShellHandler.RequestedTheme = ElementTheme.Dark;
|
||||
break;
|
||||
case "system":
|
||||
case "SYSTEM":
|
||||
ShellPage.ShellHandler.RequestedTheme = ElementTheme.Default;
|
||||
break;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user