Hi Telerik,
I have the following DomainUpDown control
And the controltemplate as follows:
My transition does not work, is there something I'm doing wrong?
Thanks
Rav
I have the following DomainUpDown control
<inputToolkit:DomainUpDown x:Name="UpDownControl_Meter" IsEditable="False" SpinnerStyle="{StaticResource ButtonSpinnerHorizontalStyle}" |
Background="White" ValueChanged="UpDownControl_Meter_ValueChanged" Height="160" BorderBrush="{StaticResource LightGray}"> |
<inputToolkit:DomainUpDown.ItemTemplate> |
<DataTemplate> |
<StackPanel VerticalAlignment="Top" Margin="10"> |
<StackPanel.Resources> |
<Style TargetType="TextBlock"> |
<Setter Property="FontFamily" Value="Arial"/> |
<Setter Property="Foreground" Value="{StaticResource DarkGray}"/> |
<Setter Property="FontSize" Value="12" /> |
</Style> |
</StackPanel.Resources> |
<TextBlock FontWeight="Bold" FontSize="15" Text="{Binding Name}" Foreground="{StaticResource SpruceGreen}" Margin="0 0 0 5" /> |
<Grid> |
<Grid.ColumnDefinitions> |
<ColumnDefinition Width="Auto"/> |
<ColumnDefinition Width="*"/> |
</Grid.ColumnDefinitions> |
<Grid.RowDefinitions> |
<RowDefinition /> |
<RowDefinition /> |
<RowDefinition /> |
<RowDefinition /> |
<RowDefinition /> |
<RowDefinition /> |
</Grid.RowDefinitions> |
<TextBlock Text="{Binding Objects[0].ObjectName}" Margin="0,2.5" /> |
<TextBlock Text="{Binding Objects[0].ObjectValueString}" Grid.Column="1" Margin="20,0,0,0" HorizontalAlignment="Right" VerticalAlignment="Center" /> |
<TextBlock Text="{Binding Objects[1].ObjectName}" Grid.Row="1" Margin="0,2.5" /> |
<TextBlock Text="{Binding Objects[1].ObjectValueString}" Grid.Row="1" Grid.Column="1" Margin="20,0,0,0" HorizontalAlignment="Right" VerticalAlignment="Center"/> |
<TextBlock Text="{Binding Objects[2].ObjectName}" Grid.Row="2" Margin="0,2.5" /> |
<TextBlock Text="{Binding Objects[2].ObjectValueString}" Grid.Row="2" Grid.Column="1" Margin="20,0,0,0" HorizontalAlignment="Right" VerticalAlignment="Center" /> |
<TextBlock Text="{Binding Objects[3].ObjectName}" Grid.Row="3" Margin="0,2.5" /> |
<TextBlock Text="{Binding Objects[3].ObjectValueString}" Grid.Row="3" Grid.Column="1" Margin="20,0,0,0" HorizontalAlignment="Right" VerticalAlignment="Center" /> |
<TextBlock Text="{Binding Objects[4].ObjectName}" Grid.Row="4" Margin="0,2.5" /> |
<TextBlock Text="{Binding Objects[4].ObjectValueString}" Grid.Row="4" Grid.Column="1" Margin="20,0,0,0" HorizontalAlignment="Right" VerticalAlignment="Center" /> |
<TextBlock Text="{Binding Objects[5].ObjectName}" Grid.Row="5" Margin="0,2.5" /> |
<TextBlock Text="{Binding Objects[5].ObjectValueString}" Grid.Row="5" Grid.Column="1" Margin="20,0,0,0" HorizontalAlignment="Right" VerticalAlignment="Center" /> |
<!--<TextBlock Text="Power Factor:" Grid.Row="4" Margin="0,1" /> |
<TextBlock Text="x.x pf" Grid.Row="4" Grid.Column="1" Margin="20,0,0,0" HorizontalAlignment="Right" VerticalAlignment="Center" />--> |
</Grid> |
</StackPanel> |
</DataTemplate> |
</inputToolkit:DomainUpDown.ItemTemplate> |
</inputToolkit:DomainUpDown> |
And the controltemplate as follows:
<ControlTemplate TargetType="inputToolkit:ButtonSpinner"> |
<Grid> |
<Border Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Padding="{TemplateBinding Padding}"> |
<Grid> |
<Grid.ColumnDefinitions> |
<ColumnDefinition Width="Auto"/> |
<ColumnDefinition Width="*"/> |
<ColumnDefinition Width="Auto"/> |
</Grid.ColumnDefinitions> |
<telerik:RadTransitionControl Content="{TemplateBinding Content}" |
Grid.Column="1" |
HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" |
VerticalAlignment="{TemplateBinding VerticalContentAlignment}"> |
<telerik:RadTransitionControl.Transition> |
<telerikTransitions:FadeTransition /> |
</telerik:RadTransitionControl.Transition> |
</telerik:RadTransitionControl> |
<!--<ContentPresenter Grid.Column="1" |
HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" |
VerticalAlignment="{TemplateBinding VerticalContentAlignment}" |
Content="{TemplateBinding Content}" IsHitTestVisible="False"/>--> |
<Rectangle Grid.Column="1" > |
<Rectangle.Fill> |
<SolidColorBrush Color="Transparent"/> |
</Rectangle.Fill> |
</Rectangle> |
<Button Grid.Column="0" IsTabStop="False" IsHitTestVisible="True"> |
<Button.Template> |
<ControlTemplate TargetType="Button"> |
<Grid Background="Transparent" /> |
</ControlTemplate> |
</Button.Template> |
</Button> |
<Button Grid.Column="2" IsTabStop="False" IsHitTestVisible="True"> |
<Button.Template> |
<ControlTemplate TargetType="Button"> |
<Grid Background="Transparent" /> |
</ControlTemplate> |
</Button.Template> |
</Button> |
<RepeatButton Grid.Column="0" Width="20" IsTabStop="False" Template="{StaticResource IncreaseButtonTemplate}" x:Name="IncreaseButton" ClickMode="Press"/> |
<RepeatButton Grid.Column="2" Width="20" IsTabStop="False" Template="{StaticResource DecreaseButtonTemplate}" x:Name="DecreaseButton" ClickMode="Press"/> |
</Grid> |
</Border> |
</Grid> |
My transition does not work, is there something I'm doing wrong?
Thanks
Rav