1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65
|
<Popup Name="PopupEtage" Placement="Bottom" IsOpen="{Binding IsOpenOutilEtage, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}" PopupAnimation="Scroll" PlacementTarget="{Binding ElementName=ButtonOutilEtage}" StaysOpen="False" Width="250">
<Border Background="White" BorderBrush="Gray" BorderThickness="1,1,1,1">
<StackPanel Margin="5,5,5,5">
<ScrollViewer Grid.Row="1" Margin="10,5,0,5"
HorizontalScrollBarVisibility="Auto"
VerticalScrollBarVisibility="Auto" >
<ListView Background="{x:Null}" BorderThickness="0" FontSize="10" Margin="0" SelectionMode="Single"
ItemsSource="{Binding ListOutilEtage , Mode=TwoWay, UpdateSourceTrigger=PropertyChanged, IsAsync=True}" SelectedItem="{Binding SelectedOutilEtage, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}" IsSynchronizedWithCurrentItem="True" Width="auto" Height="100">
<ListView.ItemContainerStyle>
<Style TargetType="ListViewItem">
<Setter Property="HorizontalContentAlignment" Value="Left" />
<Style.Triggers>
<Trigger Property="IsKeyboardFocusWithin" Value="True">
<Setter Property="IsSelected" Value="True"/>
</Trigger>
</Style.Triggers>
</Style>
</ListView.ItemContainerStyle>
<ListView.View>
<GridView ColumnHeaderContainerStyle="{StaticResource MasqueHeader}">
<GridViewColumn Width="100" DisplayMemberBinding="{Binding Local}" />
<GridViewColumn Width="110">
<GridViewColumn.CellTemplate>
<DataTemplate>
<StackPanel Orientation="Horizontal">
<Button FontFamily="Segoe UI Symbol" Content="" Background="{x:Null}" Width="20" BorderThickness="0" Foreground="#FFB9B9B9">
<i:Interaction.Triggers>
<i:EventTrigger EventName="Click" >
<i:InvokeCommandAction Command="{Binding DataContext.EtageMoinsCommand, RelativeSource={RelativeSource Mode=FindAncestor, AncestorType={x:Type ListView}}}" />
</i:EventTrigger>
</i:Interaction.Triggers>
</Button>
<TextBlock Text="{Binding Etage, Converter={StaticResource EtageConverter}}" Width="60" TextAlignment="Center"/>
<Button FontFamily="Segoe UI Symbol" Content="" Background="{x:Null}" Width="20" BorderThickness="0" Foreground="#FFB9B9B9">
<i:Interaction.Triggers>
<i:EventTrigger EventName="Click" >
<i:InvokeCommandAction Command="{Binding DataContext.EtagePlusCommand, RelativeSource={RelativeSource Mode=FindAncestor, AncestorType={x:Type ListView}}}" />
</i:EventTrigger>
</i:Interaction.Triggers>
</Button>
</StackPanel>
</DataTemplate>
</GridViewColumn.CellTemplate>
</GridViewColumn>
</GridView>
</ListView.View>
</ListView>
</ScrollViewer>
<Button HorizontalAlignment="Right" Command="{Binding AppliquezEtageCommand}">
<Button.Template>
<ControlTemplate>
<Image Source="/Apeiron;component/Utils/Images/Ok.png" Width="15" Height="15" RenderOptions.BitmapScalingMode="HighQuality" Stretch="Fill"/>
</ControlTemplate>
</Button.Template>
</Button>
</StackPanel>
</Border>
</Popup> |
Partager