6
WPF TemplateBinding a RelativeSource TemplatedParent
Jaka jest różnica między tymi dwoma wiązaniami: <ControlTemplate TargetType="{x:Type Button}"> <Border BorderBrush="{TemplateBinding Property=Background}"> <ContentPresenter /> </Border> </ControlTemplate> i <ControlTemplate TargetType="{x:Type Button}"> <Border BorderBrush="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=Background}"> <ContentPresenter /> </Border> </ControlTemplate> ?