|
@@ -2,14 +2,14 @@
|
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
|
- xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
|
|
|
- xmlns:local="clr-namespace:PixiEditor.Views.UserControls" xmlns:i="http://schemas.microsoft.com/expression/2010/interactivity" xmlns:behaviors="clr-namespace:PixiEditor.Helpers.Behaviours" xmlns:userControls="clr-namespace:PixiEditor.Views" xmlns:converters="clr-namespace:PixiEditor.Helpers.Converters"
|
|
|
|
|
|
+ xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
|
|
|
+ xmlns:i="http://schemas.microsoft.com/expression/2010/interactivity" xmlns:behaviors="clr-namespace:PixiEditor.Helpers.Behaviours" xmlns:userControls="clr-namespace:PixiEditor.Views" xmlns:converters="clr-namespace:PixiEditor.Helpers.Converters"
|
|
mc:Ignorable="d" Focusable="True"
|
|
mc:Ignorable="d" Focusable="True"
|
|
d:DesignHeight="60" d:DesignWidth="250" Name="groupControl">
|
|
d:DesignHeight="60" d:DesignWidth="250" Name="groupControl">
|
|
<UserControl.Resources>
|
|
<UserControl.Resources>
|
|
<converters:InverseBooleanConverter x:Key="InverseBooleanConverter"/>
|
|
<converters:InverseBooleanConverter x:Key="InverseBooleanConverter"/>
|
|
</UserControl.Resources>
|
|
</UserControl.Resources>
|
|
- <Border BorderThickness="0 0 0 0.5" BorderBrush="Gray" MinWidth="60" Focusable="True" >
|
|
|
|
|
|
+ <Border BorderThickness="0 0 0 0.5" BorderBrush="Gray" MinWidth="60" Focusable="True" Tag="{Binding ElementName=groupControl}">
|
|
<i:Interaction.Behaviors>
|
|
<i:Interaction.Behaviors>
|
|
<behaviors:ClearFocusOnClickBehavior/>
|
|
<behaviors:ClearFocusOnClickBehavior/>
|
|
</i:Interaction.Behaviors>
|
|
</i:Interaction.Behaviors>
|
|
@@ -29,13 +29,21 @@
|
|
<Image Source="/Images/Folder.png" Height="20"/>
|
|
<Image Source="/Images/Folder.png" Height="20"/>
|
|
<StackPanel Grid.Row="1" Orientation="Horizontal" Grid.Column="1" HorizontalAlignment="Left" Margin="5,0,0,0">
|
|
<StackPanel Grid.Row="1" Orientation="Horizontal" Grid.Column="1" HorizontalAlignment="Left" Margin="5,0,0,0">
|
|
<userControls:EditableTextBlock
|
|
<userControls:EditableTextBlock
|
|
- IsEditing="False"
|
|
|
|
FontSize="16"
|
|
FontSize="16"
|
|
VerticalAlignment="Center"
|
|
VerticalAlignment="Center"
|
|
- Text="{Binding GroupName, ElementName=groupControl, Mode=TwoWay}" />
|
|
|
|
|
|
+ IsEditing="{Binding GroupData.IsRenaming, ElementName=groupControl, Mode=TwoWay}"
|
|
|
|
+ Text="{Binding GroupData.Name, ElementName=groupControl, Mode=TwoWay}" />
|
|
</StackPanel>
|
|
</StackPanel>
|
|
</Grid>
|
|
</Grid>
|
|
<Grid DragEnter="Grid_DragEnter" Drop="Grid_Drop_Bottom" DragLeave="Grid_DragLeave" Grid.Row="2" AllowDrop="{Binding GroupData.IsExpanded, ElementName=groupControl, Converter={StaticResource InverseBooleanConverter}}" Grid.ColumnSpan="3" Background="Transparent"/>
|
|
<Grid DragEnter="Grid_DragEnter" Drop="Grid_Drop_Bottom" DragLeave="Grid_DragLeave" Grid.Row="2" AllowDrop="{Binding GroupData.IsExpanded, ElementName=groupControl, Converter={StaticResource InverseBooleanConverter}}" Grid.ColumnSpan="3" Background="Transparent"/>
|
|
</Grid>
|
|
</Grid>
|
|
|
|
+ <Border.ContextMenu>
|
|
|
|
+ <ContextMenu>
|
|
|
|
+ <MenuItem Header="Rename"
|
|
|
|
+ Command="{Binding PlacementTarget.Tag.LayersViewModel.RenameGroupCommand,
|
|
|
|
+ RelativeSource={RelativeSource AncestorType=ContextMenu}}" CommandParameter="{Binding PlacementTarget.Tag.GroupGuid, RelativeSource={RelativeSource AncestorType=ContextMenu}}">
|
|
|
|
+ </MenuItem>
|
|
|
|
+ </ContextMenu>
|
|
|
|
+ </Border.ContextMenu>
|
|
</Border>
|
|
</Border>
|
|
</UserControl>
|
|
</UserControl>
|