@@ -396,19 +396,26 @@ public void ColorizeWindow(string Mode)
396396 // Final decision on whether to use dark mode
397397 bool useDarkMode = false ;
398398
399- if ( colorScheme == "Dark" || systemBG == "Dark" )
399+ // If systemBG is not "Auto", prioritize it over ColorScheme and set the mode based on systemBG value
400+ if ( systemBG == "Dark" )
400401 {
401402 useDarkMode = true ; // Dark
402403 }
403- else if ( colorScheme == "Light" || systemBG == "Light" )
404+ else if ( systemBG == "Light" )
404405 {
405406 useDarkMode = false ; // Light
406407 }
407- else if ( colorScheme == "System" || systemBG == "Auto" )
408+ else if ( systemBG == "Auto" )
408409 {
409- useDarkMode = isSystemDark ; // Auto
410+ // If systemBG is "Auto", decide based on ColorScheme
411+ if ( colorScheme == "Dark" )
412+ useDarkMode = true ;
413+ else if ( colorScheme == "Light" )
414+ useDarkMode = false ;
415+ else
416+ useDarkMode = isSystemDark ; // Auto (based on system setting)
410417 }
411-
418+
412419 // Apply DWM Dark Mode
413420 Methods . SetWindowAttribute ( new WindowInteropHelper ( mainWindow ) . Handle , DWMWINDOWATTRIBUTE . DWMWA_USE_IMMERSIVE_DARK_MODE , useDarkMode ? 1 : 0 ) ;
414421
@@ -458,6 +465,8 @@ public void ColorizeWindow(string Mode)
458465 } , DispatcherPriority . Normal ) ;
459466 }
460467
468+
469+
461470 public bool IsBlurTheme ( )
462471 {
463472 if ( Environment . OSVersion . Version >= new Version ( 6 , 2 ) )
0 commit comments