-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathFormTeamSelect.xaml
44 lines (42 loc) · 2.63 KB
/
FormTeamSelect.xaml
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
<Window x:Class="SAR_Overlay.FormTeamSelect"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:local="clr-namespace:SAR_Overlay"
mc:Ignorable="d"
Title="Select players' teams for scenario" Height="450" Width="800" Closing="Window_Closing" Topmost="True">
<Grid>
<ListBox x:Name="ListBoxPlayers" d:ItemsSource="{d:SampleData ItemCount=5}" HorizontalContentAlignment="Stretch">
<ListBox.ItemTemplate>
<DataTemplate>
<!--<StackPanel Orientation="Horizontal" HorizontalAlignment="Stretch">
<TextBlock Text="{Binding}" HorizontalAlignment="Left"/>
<RadioButton HorizontalAlignment="Right" />
</StackPanel>-->
<Grid HorizontalAlignment="Stretch">
<StackPanel Orientation="Horizontal" HorizontalAlignment="Left">
<TextBlock Text="{Binding Path=pID, StringFormat={}[{0}]}" FontWeight="Bold" Margin="0,0,8,0"/>
<TextBlock Text="{Binding Name}" HorizontalAlignment="Left">
<TextBlock.Style>
<Style TargetType="TextBlock">
<Style.Triggers>
<DataTrigger Binding="{Binding IsBot}" Value="True">
<Setter Property="FontStyle" Value="Italic"/>
</DataTrigger>
</Style.Triggers>
</Style>
</TextBlock.Style>
</TextBlock>
</StackPanel>
<StackPanel Orientation="Horizontal" HorizontalAlignment="Right">
<RadioButton GroupName="{Binding pID}" IsChecked="{Binding Team1}" Content="Team 1" Margin="0,0,12,0"/>
<RadioButton GroupName="{Binding pID}" IsChecked="{Binding Team2}" Content="Team 2" Margin="0,0,12,0"/>
<RadioButton GroupName="{Binding pID}" IsChecked="{Binding NoTeam}" Content="No Team" Margin="0,0,12,0"/>
</StackPanel>
</Grid>
</DataTemplate>
</ListBox.ItemTemplate>
</ListBox>
</Grid>
</Window>