diff options
Diffstat (limited to 'Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/Views')
3 files changed, 89 insertions, 1 deletions
diff --git a/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/Views/ConnectedMachineView.xaml b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/Views/ConnectedMachineView.xaml index 4e3de9e60..b1502f374 100644 --- a/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/Views/ConnectedMachineView.xaml +++ b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/Views/ConnectedMachineView.xaml @@ -12,7 +12,7 @@ xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:local="clr-namespace:Tango.MachineStudio.UI.Views" mc:Ignorable="d" - d:DesignHeight="300" d:DesignWidth="300" Width="600" Height="440" Background="White" DataContext="{Binding ConnectedMachineViewVM, Source={StaticResource Locator}}"> + d:DesignHeight="300" d:DesignWidth="300" Width="600" Height="480" Background="White" DataContext="{Binding ConnectedMachineViewVM, Source={StaticResource Locator}}"> <UserControl.Resources> <converters:BooleanToVisibilityConverter x:Key="BooleanToVisibilityConverter"></converters:BooleanToVisibilityConverter> @@ -138,6 +138,8 @@ <ToggleButton IsChecked="{Binding EnableDiagnostics}" HorizontalAlignment="Left"></ToggleButton> <TextBlock FontWeight="SemiBold" Text="Enable Embedded Debug Logs:" /> <ToggleButton IsChecked="{Binding EnableEmbeddedDebugging}" HorizontalAlignment="Left"></ToggleButton> + <TextBlock FontWeight="SemiBold" Text="Enable KeepAlive:" /> + <ToggleButton IsChecked="{Binding UseKeepAlive}" HorizontalAlignment="Left"></ToggleButton> <TextBlock FontWeight="SemiBold" Text="Enable Events:" /> <ToggleButton IsChecked="{Binding EnableEventsNotification}" HorizontalAlignment="Left"></ToggleButton> </controls:TableGrid> diff --git a/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/Views/ConnectionLostView.xaml b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/Views/ConnectionLostView.xaml new file mode 100644 index 000000000..bac704fe0 --- /dev/null +++ b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/Views/ConnectionLostView.xaml @@ -0,0 +1,58 @@ +<UserControl x:Class="Tango.MachineStudio.UI.Views.ConnectionLostView" + 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:vm="clr-namespace:Tango.MachineStudio.UI.ViewModels" + xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes" + xmlns:local="clr-namespace:Tango.MachineStudio.UI.Views" + mc:Ignorable="d" + Width="559" Height="266" Background="White" d:DataContext="{d:DesignInstance Type=vm:ConnectionLostViewVM, IsDesignTimeCreatable=False}"> + <Grid> + <Grid> + <Grid.RowDefinitions> + <RowDefinition Height="80"/> + <RowDefinition Height="1*"/> + </Grid.RowDefinitions> + + <Grid> + <StackPanel Orientation="Horizontal" Margin="10"> + <Grid> + <Image Source="/Images/machine-trans.png" RenderOptions.BitmapScalingMode="Fant"></Image> + + <Ellipse Fill="#FF2626" HorizontalAlignment="Right" VerticalAlignment="Bottom" Width="30" Height="30" Margin="0 0 -5 -5"> + </Ellipse> + <materialDesign:PackIcon Foreground="White" Kind="LanDisconnect" HorizontalAlignment="Right" VerticalAlignment="Bottom" Width="20" Height="20" Margin="0 0 0 0" /> + </Grid> + <TextBlock Text="Connection Lost" VerticalAlignment="Center" Margin="10 0 0 0" FontSize="20"></TextBlock> + </StackPanel> + </Grid> + + <Grid Grid.Row="1" Margin="10 0 10 10"> + <Grid.RowDefinitions> + <RowDefinition Height="1*"/> + <RowDefinition Height="50"/> + </Grid.RowDefinitions> + + <Grid> + <StackPanel Margin="0 10 0 0" > + <TextBlock TextWrapping="Wrap"> + <Run>The machine connection has entered an invalid or inactive state and will be regarded as.</Run> + <LineBreak/> + <Run>disconnected.</Run> + </TextBlock> + + <TextBlock Margin="0 20 0 0" FontWeight="SemiBold">Reason:</TextBlock> + <TextBlock Foreground="Gray" Margin="0 2 0 0" Text="{Binding Exception}" Height="75" TextWrapping="Wrap" TextTrimming="CharacterEllipsis"> + + </TextBlock> + </StackPanel> + </Grid> + + <Grid Grid.Row="1"> + <Button HorizontalAlignment="Right" Width="140" Command="{Binding OKCommand}">CLOSE</Button> + </Grid> + </Grid> + </Grid> + </Grid> +</UserControl> diff --git a/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/Views/ConnectionLostView.xaml.cs b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/Views/ConnectionLostView.xaml.cs new file mode 100644 index 000000000..50f0429a4 --- /dev/null +++ b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/Views/ConnectionLostView.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.UI.Views +{ + /// <summary> + /// Interaction logic for ConnectionLostView.xaml + /// </summary> + public partial class ConnectionLostView : UserControl + { + public ConnectionLostView() + { + InitializeComponent(); + } + } +} |
