aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/Views/MainView.xaml
diff options
context:
space:
mode:
authorRoy Ben-Shabat <Roy@Twine-s.com>2018-04-09 18:30:58 +0300
committerRoy Ben-Shabat <Roy@Twine-s.com>2018-04-09 18:30:58 +0300
commita898decf18c4c0ed56d020dc09df55df1ca0263a (patch)
tree66140670047d9ec9d7a0bbeb2851a84868b9515c /Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/Views/MainView.xaml
parent4cd266e13bdb3e27ca77eba3b47278b57a0dcd8d (diff)
downloadTango-a898decf18c4c0ed56d020dc09df55df1ca0263a.tar.gz
Tango-a898decf18c4c0ed56d020dc09df55df1ca0263a.zip
Lots of changes :/
Diffstat (limited to 'Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/Views/MainView.xaml')
-rw-r--r--Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/Views/MainView.xaml88
1 files changed, 64 insertions, 24 deletions
diff --git a/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/Views/MainView.xaml b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/Views/MainView.xaml
index b7a4cc93f..3301fd9f3 100644
--- a/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/Views/MainView.xaml
+++ b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/Views/MainView.xaml
@@ -172,6 +172,24 @@
</StackPanel>
</Button>
<Separator/>
+ <Button Command="{Binding ToggleSpeechCommand}">
+ <StackPanel Orientation="Horizontal">
+ <materialDesign:PackIcon Width="24" Height="24">
+ <materialDesign:PackIcon.Style>
+ <Style TargetType="materialDesign:PackIcon">
+ <Setter Property="Kind" Value="VolumeHigh"></Setter>
+ <Style.Triggers>
+ <DataTrigger Binding="{Binding SpeechProvider.Mute}" Value="True">
+ <Setter Property="Kind" Value="VolumeOff"></Setter>
+ </DataTrigger>
+ </Style.Triggers>
+ </Style>
+ </materialDesign:PackIcon.Style>
+ </materialDesign:PackIcon>
+ <TextBlock Margin="5 0 0 0" VerticalAlignment="Center">Speech</TextBlock>
+ </StackPanel>
+ </Button>
+ <Separator/>
<Button Command="{Binding ExitCommand}">
<StackPanel Orientation="Horizontal">
<materialDesign:PackIcon Kind="CloseCircleOutline" Width="24" Height="24" />
@@ -437,37 +455,59 @@
<ItemsControl.ItemTemplate>
<DataTemplate DataType="{x:Type entities:MachinesEvent}">
<Border BorderThickness="0 0 0 1" BorderBrush="#E1E1E1" Padding="5">
- <StackPanel>
- <StackPanel Orientation="Horizontal">
- <materialDesign:PackIcon Width="24" Height="24">
- <materialDesign:PackIcon.Style>
- <Style TargetType="materialDesign:PackIcon">
- <Setter Property="Kind" Value="AlertCircle"></Setter>
- <Setter Property="Foreground" Value="#464646"></Setter>
+ <DockPanel>
+ <Grid DockPanel.Dock="Right" HorizontalAlignment="Right" VerticalAlignment="Center">
+ <ContentControl>
+ <ContentControl.Style>
+ <Style TargetType="ContentControl">
+ <Setter Property="Content" Value="{x:Null}"></Setter>
<Style.Triggers>
- <DataTrigger Binding="{Binding Category}" Value="Warning">
- <Setter Property="Kind" Value="Alert"></Setter>
- <Setter Property="Foreground" Value="#FFA300"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding Category}" Value="Error">
- <Setter Property="Kind" Value="AlertOctagon"></Setter>
- <Setter Property="Foreground" Value="#FF5C5C"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding Category}" Value="Critical">
- <Setter Property="Kind" Value="BellPlus"></Setter>
- <Setter Property="Foreground" Value="Red"></Setter>
+ <DataTrigger Binding="{Binding EventType.HtmlPage,Converter={StaticResource NullObjectToBooleanConverter}}" Value="True">
+ <Setter Property="Content">
+ <Setter.Value>
+ <Button Style="{StaticResource emptyButton}" Cursor="Hand" Margin="5" Command="{Binding RelativeSource={RelativeSource AncestorType=UserControl},Path=DataContext.ResolveMachineEventCommand}" CommandParameter="{Binding}">
+ <materialDesign:PackIcon Kind="TelevisionGuide" Width="24" Height="24" />
+ </Button>
+ </Setter.Value>
+ </Setter>
</DataTrigger>
</Style.Triggers>
</Style>
- </materialDesign:PackIcon.Style>
- </materialDesign:PackIcon>
+ </ContentControl.Style>
+ </ContentControl>
+ </Grid>
+ <StackPanel>
+ <StackPanel Orientation="Horizontal">
+ <materialDesign:PackIcon Width="24" Height="24">
+ <materialDesign:PackIcon.Style>
+ <Style TargetType="materialDesign:PackIcon">
+ <Setter Property="Kind" Value="AlertCircle"></Setter>
+ <Setter Property="Foreground" Value="#464646"></Setter>
+ <Style.Triggers>
+ <DataTrigger Binding="{Binding Category}" Value="Warning">
+ <Setter Property="Kind" Value="Alert"></Setter>
+ <Setter Property="Foreground" Value="#FFA300"></Setter>
+ </DataTrigger>
+ <DataTrigger Binding="{Binding Category}" Value="Error">
+ <Setter Property="Kind" Value="AlertOctagon"></Setter>
+ <Setter Property="Foreground" Value="#FF5C5C"></Setter>
+ </DataTrigger>
+ <DataTrigger Binding="{Binding Category}" Value="Critical">
+ <Setter Property="Kind" Value="BellPlus"></Setter>
+ <Setter Property="Foreground" Value="Red"></Setter>
+ </DataTrigger>
+ </Style.Triggers>
+ </Style>
+ </materialDesign:PackIcon.Style>
+ </materialDesign:PackIcon>
- <StackPanel Margin="10 0 0 0" VerticalAlignment="Top">
- <TextBlock Text="{Binding EventType.Name}"></TextBlock>
- <TextBlock Margin="0 5 0 0" Text="{Binding Description}" FontSize="10" Foreground="DimGray" TextWrapping="Wrap"></TextBlock>
+ <StackPanel Margin="10 0 0 0" VerticalAlignment="Top">
+ <TextBlock Text="{Binding EventType.Name}"></TextBlock>
+ <TextBlock Margin="0 5 0 0" Text="{Binding Description}" FontSize="10" Foreground="DimGray" TextWrapping="Wrap"></TextBlock>
+ </StackPanel>
</StackPanel>
</StackPanel>
- </StackPanel>
+ </DockPanel>
</Border>
</DataTemplate>
</ItemsControl.ItemTemplate>