diff options
Diffstat (limited to 'Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Synchronization/Views')
4 files changed, 99 insertions, 21 deletions
diff --git a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Synchronization/Views/DirectSynchronizationView.xaml b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Synchronization/Views/DirectSynchronizationView.xaml new file mode 100644 index 000000000..7dc0cdacc --- /dev/null +++ b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Synchronization/Views/DirectSynchronizationView.xaml @@ -0,0 +1,33 @@ +<UserControl x:Class="Tango.MachineStudio.Synchronization.Views.DirectSynchronizationView" + 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:mahapps="http://metro.mahapps.com/winfx/xaml/controls" + xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes" + xmlns:synchronization="clr-namespace:Tango.Synchronization;assembly=Tango.Synchronization" + xmlns:global="clr-namespace:Tango.MachineStudio.Synchronization" + xmlns:local="clr-namespace:Tango.MachineStudio.Synchronization.Views" + mc:Ignorable="d" + d:DesignHeight="720" d:DesignWidth="1280" Background="White" DataContext="{x:Static global:ViewModelLocator.DirectSynchronizationViewVM}"> + <Grid> + <Grid> + <Grid.ColumnDefinitions> + <ColumnDefinition Width="300"/> + <ColumnDefinition Width="1*"/> + </Grid.ColumnDefinitions> + + <ListBox ItemsSource="{Binding Scanner.AvailableMachines}" SelectedItem="{Binding SelectedMachine}"> + <ListBox.ItemTemplate> + <DataTemplate> + <StackPanel> + <TextBlock Text="{Binding SerialNumber}"></TextBlock> + <TextBlock Text="{Binding Organization}"></TextBlock> + </StackPanel> + </DataTemplate> + </ListBox.ItemTemplate> + </ListBox> + + </Grid> + </Grid> +</UserControl> diff --git a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Synchronization/Views/DirectSynchronizationView.xaml.cs b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Synchronization/Views/DirectSynchronizationView.xaml.cs new file mode 100644 index 000000000..5a7c12646 --- /dev/null +++ b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Synchronization/Views/DirectSynchronizationView.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.Synchronization.Views +{ + /// <summary> + /// Interaction logic for DirectSynchronizationView.xaml + /// </summary> + public partial class DirectSynchronizationView : UserControl + { + public DirectSynchronizationView() + { + InitializeComponent(); + } + } +} diff --git a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Synchronization/Views/MainView.xaml b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Synchronization/Views/MainView.xaml index bac530777..664dac229 100644 --- a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Synchronization/Views/MainView.xaml +++ b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Synchronization/Views/MainView.xaml @@ -28,6 +28,9 @@ <ContentControl Tag="RemoteSynchronizationView"> <local:RemoteSynchronizationView></local:RemoteSynchronizationView> </ContentControl> + <ContentControl Tag="DirectSynchronizationView"> + <local:DirectSynchronizationView></local:DirectSynchronizationView> + </ContentControl> </controls:MultiTransitionControl.Controls> </controls:MultiTransitionControl> diff --git a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Synchronization/Views/MenuView.xaml b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Synchronization/Views/MenuView.xaml index 6210ca94c..67501743b 100644 --- a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Synchronization/Views/MenuView.xaml +++ b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Synchronization/Views/MenuView.xaml @@ -10,17 +10,34 @@ d:DesignHeight="720" d:DesignWidth="1280" DataContext="{x:Static global:ViewModelLocator.MenuViewVM}"> <Grid> <Grid> - <Grid> - <Grid.ColumnDefinitions> - <ColumnDefinition Width="1*"/> - <ColumnDefinition Width="1*"/> - </Grid.ColumnDefinitions> + <UniformGrid Columns="3"> + <Grid VerticalAlignment="Center"> + <StackPanel> + <StackPanel HorizontalAlignment="Center" Margin="0 0 0 30"> + <TextBlock TextAlignment="Center" FontSize="25">Local Synchronization</TextBlock> + <TextBlock TextAlignment="Center" FontSize="14" Foreground="#303030">Synchronize two SQLite local database files.</TextBlock> + </StackPanel> + <Viewbox RenderOptions.BitmapScalingMode="Fant" Width="400"> + <Grid Width="450"> + <StackPanel> + <StackPanel Orientation="Horizontal"> + <Image Source="../Images/sqlite.png" Width="160"></Image> + <Image Source="../Images/arrow_right.png" Width="100" RenderTransformOrigin="0.5,0.5"></Image> + <Image Source="../Images/sqlite.png" Width="130"></Image> + </StackPanel> + + <Button Command="{Binding StartLocalSyncCommand}" Height="80" Margin="0 20 0 0" HorizontalAlignment="Center" Padding="10" FontSize="20" Width="200">START</Button> + </StackPanel> + </Grid> + </Viewbox> + </StackPanel> + </Grid> <Grid VerticalAlignment="Center"> <StackPanel> <StackPanel HorizontalAlignment="Center" Margin="0 0 0 30"> - <TextBlock TextAlignment="Center" FontSize="25">Remote Synchronization</TextBlock> - <TextBlock TextAlignment="Center" FontSize="14" Foreground="#303030">Synchronize local SQLite database file with the remote Twine database.</TextBlock> + <TextBlock TextAlignment="Center" FontSize="25">Direct Remote Synchronization</TextBlock> + <TextBlock TextAlignment="Center" FontSize="14" Foreground="#303030">Connect and synchronized a Tango machine over the network.</TextBlock> </StackPanel> <Viewbox RenderOptions.BitmapScalingMode="Fant" Width="400"> <Grid Width="450"> @@ -28,42 +45,39 @@ <StackPanel Orientation="Horizontal"> <Image Source="../Images/remote-db.png" Width="200"></Image> <Image Source="../Images/arrow_right.png" Width="100"></Image> - <Image Source="../Images/android-phone-color.png" Width="180"></Image> + <Image Source="../Images/machine-trans.png" Width="120"></Image> </StackPanel> - <Button Command="{Binding StartRemoteSyncCommand}" Height="80" Margin="20 20 10 0" HorizontalAlignment="Right" Padding="10" FontSize="20" Width="200">START</Button> + <Button Command="{Binding StartDirectRemoteSyncCommand}" Height="80" Margin="0 20 0 0" HorizontalAlignment="Center" Padding="10" FontSize="20" Width="200">START</Button> </StackPanel> </Grid> </Viewbox> </StackPanel> </Grid> - <Grid VerticalAlignment="Center" Grid.Column="1"> + <Grid VerticalAlignment="Center"> <StackPanel> <StackPanel HorizontalAlignment="Center" Margin="0 0 0 30"> - <TextBlock TextAlignment="Center" FontSize="25">Local Synchronization</TextBlock> - <TextBlock TextAlignment="Center" FontSize="14" Foreground="#303030">Synchronize two SQLite local database files.</TextBlock> + <TextBlock TextAlignment="Center" FontSize="25">Semi Remote Synchronization</TextBlock> + <TextBlock TextAlignment="Center" FontSize="14" Foreground="#303030">Synchronize local SQLite database file with the remote Twine database.</TextBlock> </StackPanel> <Viewbox RenderOptions.BitmapScalingMode="Fant" Width="400"> <Grid Width="450"> <StackPanel> <StackPanel Orientation="Horizontal"> - <Image Source="../Images/sqlite.png" Width="160"></Image> - <Image Source="../Images/arrow_right.png" Width="100" RenderTransformOrigin="0.5,0.5"> - <Image.RenderTransform> - <RotateTransform Angle="180"></RotateTransform> - </Image.RenderTransform> - </Image> - <Image Source="../Images/sqlite.png" Width="160"></Image> + <Image Source="../Images/remote-db.png" Width="200"></Image> + <Image Source="../Images/arrow_right.png" Width="100"></Image> + <Image Source="../Images/sqlite.png" Width="120"></Image> </StackPanel> - <Button Command="{Binding StartLocalSyncCommand}" Height="80" Margin="5 20 20 0" HorizontalAlignment="Left" Padding="10" FontSize="20" Width="200">START</Button> + <Button Command="{Binding StartRemoteSyncCommand}" Height="80" Margin="0 20 0 0" HorizontalAlignment="Center" Padding="10" FontSize="20" Width="200">START</Button> </StackPanel> </Grid> </Viewbox> </StackPanel> </Grid> - </Grid> + + </UniformGrid> </Grid> </Grid> </UserControl> |
