blob: 426a56f51b333a3915a90edb930745458ed48c58 (
plain)
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
|
<UserControl x:Class="Tango.MachineStudio.RML.Views.AddLiquidFactorView"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:local="clr-namespace:Tango.MachineStudio.RML.Views"
xmlns:converters="clr-namespace:Tango.SharedUI.Converters;assembly=Tango.SharedUI"
xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes"
xmlns:vm="clr-namespace:Tango.MachineStudio.RML.ViewModels"
mc:Ignorable="d"
d:DesignHeight="220" d:DesignWidth="600" Background="Transparent" d:DataContext="{d:DesignInstance Type=vm:AddLiquidFactorViewVM, IsDesignTimeCreatable=False}">
<UserControl.Resources>
<converters:ColorToIntegerConverter x:Key="ColorToIntegerConverter"></converters:ColorToIntegerConverter>
</UserControl.Resources>
<Grid>
<DockPanel LastChildFill="True">
<StackPanel Orientation="Horizontal" VerticalAlignment="Bottom" HorizontalAlignment="Right" DockPanel.Dock="Bottom">
<Button Style="{StaticResource MaterialDesignFlatButton}" IsDefault="True" Margin="0 8 8 0" Command="{Binding OKCommand}">
ACCEPT
</Button>
<Button Style="{StaticResource MaterialDesignFlatButton}" IsCancel="False" Margin="0 8 8 0" Command="{Binding CloseCommand}">
CANCEL
</Button>
</StackPanel>
<Grid>
<StackPanel VerticalAlignment="Top" Margin="0 30 0 0">
<StackPanel Orientation="Horizontal">
<materialDesign:PackIcon Kind="Plus" VerticalAlignment="Top" Width="50" Height="50" Foreground="{StaticResource GreenBrush100}" />
<TextBlock Padding="0 10 0 0" TextWrapping="Wrap" Margin="10 0 0 0" VerticalAlignment="Top" FontSize="14" Text="ADD LIQUID FACTOR" Width="400"></TextBlock>
</StackPanel>
<ComboBox Margin="60 0 20 0" ItemsSource="{Binding LiquidTypes}" SelectedItem="{Binding SelectedLiquidType}" SelectedIndex="0">
<ComboBox.ItemTemplate>
<DataTemplate>
<StackPanel Orientation="Horizontal">
<Rectangle Width="32" Height="32" Stroke="#2B2B2B" StrokeThickness="1">
<Rectangle.Fill>
<SolidColorBrush Color="{Binding Color,Converter={StaticResource ColorToIntegerConverter}}" />
</Rectangle.Fill>
</Rectangle>
<TextBlock VerticalAlignment="Center" Margin="10 0 0 0">
<Run Text="{Binding Name}"></Run>,
<Run Foreground="Gray" FontSize="10">v</Run><Run Foreground="Gray" FontSize="10" Text="{Binding Version}"></Run>
</TextBlock>
</StackPanel>
</DataTemplate>
</ComboBox.ItemTemplate>
</ComboBox>
</StackPanel>
</Grid>
</DockPanel>
</Grid>
</UserControl>
|