|
369 | 369 | SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" />
|
370 | 370 | <Grid x:Name="PART_InnerGrid" Margin="2">
|
371 | 371 | <Grid.ColumnDefinitions>
|
372 |
| - <ColumnDefinition Width="*" /> |
| 372 | + <ColumnDefinition Width="Auto" /> |
373 | 373 | <ColumnDefinition Width="Auto" />
|
374 | 374 | <ColumnDefinition x:Name="ButtonColumn" Width="Auto" />
|
375 | 375 | </Grid.ColumnDefinitions>
|
|
450 | 450 | Visibility="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(Controls:ControlsHelper.DisabledVisualElementVisibility), Mode=OneWay}" />
|
451 | 451 | </Grid>
|
452 | 452 | <ControlTemplate.Triggers>
|
| 453 | + <DataTrigger Binding="{Binding RelativeSource={RelativeSource Self}, Path=(Controls:TextBoxHelper.ButtonsAlignment)}" Value="Left"> |
| 454 | + <Setter TargetName="ButtonColumn" Property="Width" Value="*" /> |
| 455 | + <Setter TargetName="PART_ClearText" Property="Grid.Column" Value="0" /> |
| 456 | + <Setter TargetName="PART_ContentHost" Property="Grid.Column" Value="1" /> |
| 457 | + <Setter TargetName="PART_Message" Property="Grid.Column" Value="1" /> |
| 458 | + </DataTrigger> |
| 459 | + |
453 | 460 | <DataTrigger Binding="{Binding RelativeSource={RelativeSource Self}, Path=Password, Mode=OneWay}" Value="">
|
454 | 461 | <Setter TargetName="PART_Message" Property="Visibility" Value="Visible" />
|
455 | 462 | </DataTrigger>
|
|
468 | 475 | </MultiDataTrigger.ExitActions>
|
469 | 476 | </MultiDataTrigger>
|
470 | 477 |
|
| 478 | + <MultiDataTrigger> |
| 479 | + <MultiDataTrigger.Conditions> |
| 480 | + <Condition Binding="{Binding RelativeSource={RelativeSource Self}, Path=(Controls:TextBoxHelper.ButtonsAlignment)}" Value="Right" /> |
| 481 | + <Condition Binding="{Binding RelativeSource={RelativeSource Self}, Path=(Controls:TextBoxHelper.TextButton)}" Value="False" /> |
| 482 | + </MultiDataTrigger.Conditions> |
| 483 | + <Setter TargetName="PART_ContentHost" Property="Grid.ColumnSpan" Value="2" /> |
| 484 | + <Setter TargetName="PART_Message" Property="Grid.ColumnSpan" Value="2" /> |
| 485 | + </MultiDataTrigger> |
| 486 | + |
471 | 487 | <Trigger Property="IsMouseOver" Value="True">
|
472 | 488 | <Setter TargetName="Base" Property="BorderBrush" Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(Controls:ControlsHelper.MouseOverBorderBrush)}" />
|
473 | 489 | </Trigger>
|
|
0 commit comments