Fix button theme setup bug

This commit is contained in:
chinboy
2025-07-08 17:10:54 +08:00
parent 5ac2cc15b6
commit 8461ecee78
+8 -5
View File
@@ -379,17 +379,20 @@ public class Button : AvaloniaButton,
{
SetupShadows();
}
else if (e.Property == ButtonTypeProperty)
{
SetupControlThemeBindings();
}
else if (e.Property == IsMotionEnabledProperty ||
e.Property == IsWaveSpiritEnabledProperty)
{
ConfigureTransitions();
}
}
if (this.IsAttachedToLogicalTree())
{
if (e.Property == ButtonTypeProperty)
{
SetupControlThemeBindings();
}
}
}
protected virtual void SetupControlThemeBindings()