aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.RML/Views
diff options
context:
space:
mode:
Diffstat (limited to 'Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.RML/Views')
-rw-r--r--Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.RML/Views/RmlActiveSitesDialog.xaml71
-rw-r--r--Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.RML/Views/RmlActiveSitesDialog.xaml.cs28
-rw-r--r--Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.RML/Views/RmlsView.xaml19
3 files changed, 118 insertions, 0 deletions
diff --git a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.RML/Views/RmlActiveSitesDialog.xaml b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.RML/Views/RmlActiveSitesDialog.xaml
new file mode 100644
index 000000000..b02380508
--- /dev/null
+++ b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.RML/Views/RmlActiveSitesDialog.xaml
@@ -0,0 +1,71 @@
+<UserControl x:Class="Tango.MachineStudio.RML.Views.RmlActiveSitesDialog"
+ 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:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes"
+ xmlns:vm="clr-namespace:Tango.MachineStudio.RML.ViewModels"
+ xmlns:converters="clr-namespace:Tango.SharedUI.Converters;assembly=Tango.SharedUI"
+ xmlns:local="clr-namespace:Tango.MachineStudio.RML.Views"
+ mc:Ignorable="d"
+ d:DesignHeight="400" d:DesignWidth="400" Height="600" Width="500" Background="{StaticResource Dialog.Background}" d:DataContext="{d:DesignInstance Type=vm:RmlDeleteDialogViewVM, IsDesignTimeCreatable=False}" Foreground="{StaticResource Dialog.Foreground}">
+
+ <UserControl.Resources>
+ <Style x:Key="GridStyle" TargetType="DataGrid" BasedOn="{StaticResource {x:Type DataGrid}}">
+ <Setter Property="AutoGenerateColumns" Value="False"></Setter>
+ <Setter Property="SelectionMode" Value="Single"></Setter>
+ <Setter Property="SelectionUnit" Value="FullRow"></Setter>
+ <Setter Property="IsReadOnly" Value="True"></Setter>
+ </Style>
+ <Style x:Key="CellStyle" TargetType="DataGridCell" BasedOn="{StaticResource {x:Type DataGridCell}}">
+ <Setter Property="Template">
+ <Setter.Value>
+ <ControlTemplate TargetType="{x:Type DataGridCell}">
+ <Grid Background="{TemplateBinding Background}">
+ <ContentPresenter VerticalAlignment="Center" Margin="8" />
+ </Grid>
+ </ControlTemplate>
+ </Setter.Value>
+ </Setter>
+ <Setter Property="BorderThickness" Value="0"/>
+ <Setter Property="FocusVisualStyle" Value="{x:Null}"/>
+ <Setter Property="VerticalContentAlignment" Value="Center"></Setter>
+ <Style.Triggers>
+ <Trigger Property="IsSelected" Value="True">
+ <Setter Property="BorderThickness" Value="0"/>
+ <Setter Property="BorderBrush" Value="Cyan"/>
+ </Trigger>
+ </Style.Triggers>
+ </Style>
+
+ </UserControl.Resources>
+
+ <Grid>
+ <DockPanel Margin="10">
+ <StackPanel Orientation="Horizontal" VerticalAlignment="Bottom" HorizontalAlignment="Center" DockPanel.Dock="Bottom">
+ <Button Command="{Binding CloseCommand}" Width="140" Height="40" Margin="0 0 10 0">
+ Close
+ </Button>
+ </StackPanel>
+
+ <Grid DockPanel.Dock="Top">
+ <DockPanel HorizontalAlignment="Stretch">
+ <Grid DockPanel.Dock="Left">
+ <materialDesign:PackIcon Kind="InformationVariant" Foreground="{StaticResource AccentColorBrush}" Width="28" Height="28" />
+ </Grid>
+ <TextBlock DockPanel.Dock="Left" Margin="10 5 0 0" HorizontalAlignment="Left" VerticalAlignment="Center" FontSize="18" TextWrapping="Wrap" Text="{Binding RMLName}"/>
+ </DockPanel>
+ </Grid>
+ <Grid DockPanel.Dock="Top" Margin="0 20 0 20">
+ <materialDesign:Card Background="{DynamicResource MaterialDesignBackground}" VerticalAlignment="Stretch">
+ <DataGrid ItemsSource="{Binding RMLSiteNamesList}" Style="{StaticResource GridStyle}" CellStyle="{StaticResource CellStyle}">
+ <DataGrid.Columns>
+ <DataGridTextColumn Header="SITE NAME" IsReadOnly="True" Binding="{Binding }" Width="1*" />
+ </DataGrid.Columns>
+ </DataGrid>
+ </materialDesign:Card>
+ </Grid>
+
+ </DockPanel>
+ </Grid>
+</UserControl>
diff --git a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.RML/Views/RmlActiveSitesDialog.xaml.cs b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.RML/Views/RmlActiveSitesDialog.xaml.cs
new file mode 100644
index 000000000..f9c020506
--- /dev/null
+++ b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.RML/Views/RmlActiveSitesDialog.xaml.cs
@@ -0,0 +1,28 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+using System.Windows;
+using System.Windows.Controls;
+using System.Windows.Data;
+using System.Windows.Documents;
+using System.Windows.Input;
+using System.Windows.Media;
+using System.Windows.Media.Imaging;
+using System.Windows.Navigation;
+using System.Windows.Shapes;
+
+namespace Tango.MachineStudio.RML.Views
+{
+ /// <summary>
+ /// Interaction logic for RmlActiveSitesDialog.xaml
+ /// </summary>
+ public partial class RmlActiveSitesDialog : UserControl
+ {
+ public RmlActiveSitesDialog()
+ {
+ InitializeComponent();
+ }
+ }
+}
diff --git a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.RML/Views/RmlsView.xaml b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.RML/Views/RmlsView.xaml
index 9c684c052..2c0f77937 100644
--- a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.RML/Views/RmlsView.xaml
+++ b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.RML/Views/RmlsView.xaml
@@ -77,6 +77,25 @@
<TextBlock VerticalAlignment="Center" Margin="10 0 0 0" TextDecorations="Underline">Export Thread File</TextBlock>
</StackPanel>
</Button>
+
+ <Button x:Name="ShowActiveInSitesBtn" Margin="30 0 0 0" Command="{Binding ActivatedInSitesCommand}" Foreground="{StaticResource BlackForegroundBrush}" FontSize="16" Style="{StaticResource emptyButton}" Cursor="Hand">
+ <StackPanel Orientation="Horizontal">
+ <materialDesign:PackIcon Kind="InformationVariant" VerticalAlignment="Center" Width="26" Height="26" Foreground="Blue"/>
+ <TextBlock VerticalAlignment="Center" Margin="0 0 0 0" TextDecorations="Underline" Text="Activated in sites…">
+ <TextBlock.Style>
+ <Style TargetType="TextBlock">
+ <Setter Property="Foreground" Value="{StaticResource BlackForegroundBrush}" />
+ <Style.Triggers>
+ <DataTrigger Binding="{Binding ElementName=ShowActiveInSitesBtn, Path=IsEnabled}" Value="False">
+ <Setter Property="Foreground" Value="{StaticResource GrayBrush}" />
+ </DataTrigger>
+ </Style.Triggers>
+ </Style>
+ </TextBlock.Style>
+ </TextBlock>
+ </StackPanel>
+ </Button>
+
</StackPanel>
</StackPanel>
</Grid>