I have an application which uses some attached behaviours/properties to set the background of controls when there values change. As soon as I apply the metro visual style to any parent control my attached behaviors no longer seem to work on an child controls. e.g
syncfusion:SkinStorage.VisualStyle="Metro"
The behavior no longer works.
<Style TargetType="Control" x:Key="ControlBaseStyle">
<Setter Property="Validation.ErrorTemplate" Value="{StaticResource DefaultErrorTemplate}" />
<Setter Property="behaviors:ChangeBehavior.IsActive" Value="True" />
<Style.Triggers>
<Trigger Property="behaviors:ChangeBehavior.IsChanged" Value="True">
<Setter Property="Background" Value="{StaticResource IsChangedBackgroundBrush}" />
<Setter Property="ToolTip" Value="{Binding RelativeSource={RelativeSource Self}, Path=(behaviors:ChangeBehavior.OriginalValue)}" />
</Trigger>
<Trigger Property="Validation.HasError" Value="True">
<Setter Property="Background" Value="{StaticResource HasErrorBackgroundBrush}" />
</Trigger>
</Style.Triggers>
</Style>
<Style TargetType="TextBox" BasedOn="{StaticResource ControlBaseStyle}"/>
I have attached a demo project demonstrating the problem with 2 tab controls, one is using the Metro theme and doesn't work, the other is not and does work.
Thanks in advance for your help.
Adam
Attachment:
SyncFusionBehaviorProblem_f92c0a06.zip