Skip to content

Commit b41bd1e

Browse files
committed
Fix theme not work with 'Use System Setting'
1 parent f1b101b commit b41bd1e

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

IPConfig/Helpers/ThemeManager.cs

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -47,13 +47,6 @@ private set
4747

4848
public static void UpdateSkin(SkinType? skin)
4949
{
50-
if (skin == CurrentSkinTypeMode)
51-
{
52-
return;
53-
}
54-
55-
ThemeChanging?.Invoke(null, skin);
56-
5750
SkinType actualSkinType;
5851

5952
if (skin is null)
@@ -65,6 +58,13 @@ public static void UpdateSkin(SkinType? skin)
6558
actualSkinType = skin.Value;
6659
}
6760

61+
if (actualSkinType == CurrentSkinType)
62+
{
63+
return;
64+
}
65+
66+
ThemeChanging?.Invoke(null, skin);
67+
6868
App.Current.Resources.MergedDictionaries.Clear();
6969

7070
App.Current.Resources.MergedDictionaries.Add(new ResourceDictionary {

0 commit comments

Comments
 (0)