ورود

View Full Version : تداخل بین Node های فرزند و پدر



exlord
دوشنبه 10 خرداد 1389, 14:13 عصر
<TreeViewItem x:Class="Exlord.Controls.MyTreeViewItem"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
mc:Ignorable="d"
MouseEnter="TreeViewItem_MouseEnter">
<TreeViewItem.Background>
<LinearGradientBrush EndPoint="0.504,1.5" StartPoint="0.504,0.03" >
<GradientStop Color="White" Offset="0" x:Name="gs1" />
<GradientStop Color="#FFFFFFFF" Offset="0.567" x:Name="gs2"/>
</LinearGradientBrush>
</TreeViewItem.Background>
<TreeViewItem.Triggers>
<EventTrigger RoutedEvent="TreeViewItem.MouseEnter">
<BeginStoryboard>
<Storyboard>
<ColorAnimation Storyboard.TargetName="gs1" Storyboard.TargetProperty="Color" To="#FFFFC934" Duration="0:0:0.3"/>
</Storyboard>
</BeginStoryboard>
</EventTrigger>
<EventTrigger RoutedEvent="TreeViewItem.MouseLeave" >
<BeginStoryboard>
<Storyboard>
<ColorAnimation Storyboard.TargetName="gs1" Storyboard.TargetProperty="Color" To="White" Duration="0:0:0.3"/>
</Storyboard>
</BeginStoryboard>
</EventTrigger>
</TreeViewItem.Triggers>
</TreeViewItem>
وقتی موس رو میبرم روی آیتم های فرزند آتم های پدر هم افکت مربوط به mouseEnter رو میگیرن ..... :عصبانی++::افسرده: چیکار کنم که این اتفاق نیفته ؟؟؟؟

exlord
سه شنبه 11 خرداد 1389, 12:41 عصر
از اساتید کسی بلد نیست ؟؟