aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.DB
diff options
context:
space:
mode:
authorRoy Ben-Shabat <Roy@Twine-s.com>2017-12-13 19:28:19 +0200
committerRoy Ben-Shabat <Roy@Twine-s.com>2017-12-13 19:28:19 +0200
commitb6615cec573616c9b6469c010982dda689ee3844 (patch)
tree0ba4c61fecc5c8eeb9cdcd8168a91e68ec60b845 /Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.DB
parent471daec51d0fc9437f8551d5d48c9fa2fb031871 (diff)
downloadTango-b6615cec573616c9b6469c010982dda689ee3844.tar.gz
Tango-b6615cec573616c9b6469c010982dda689ee3844.zip
Modified DB Module design.
Diffstat (limited to 'Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.DB')
-rw-r--r--Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.DB/Images/seamless-grid.jpgbin0 -> 12022 bytes
-rw-r--r--Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.DB/Tango.MachineStudio.DB.csproj3
-rw-r--r--Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.DB/Views/MainDBView.xaml89
3 files changed, 37 insertions, 55 deletions
diff --git a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.DB/Images/seamless-grid.jpg b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.DB/Images/seamless-grid.jpg
new file mode 100644
index 000000000..59bb9c370
--- /dev/null
+++ b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.DB/Images/seamless-grid.jpg
Binary files differ
diff --git a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.DB/Tango.MachineStudio.DB.csproj b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.DB/Tango.MachineStudio.DB.csproj
index 5bfd19494..0d6304c44 100644
--- a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.DB/Tango.MachineStudio.DB.csproj
+++ b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.DB/Tango.MachineStudio.DB.csproj
@@ -222,5 +222,8 @@
<ItemGroup>
<Resource Include="Images\db.png" />
</ItemGroup>
+ <ItemGroup>
+ <Resource Include="Images\seamless-grid.jpg" />
+ </ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
</Project> \ No newline at end of file
diff --git a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.DB/Views/MainDBView.xaml b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.DB/Views/MainDBView.xaml
index d3149849f..5ba51fea8 100644
--- a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.DB/Views/MainDBView.xaml
+++ b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.DB/Views/MainDBView.xaml
@@ -7,68 +7,47 @@
xmlns:dragablz="clr-namespace:Dragablz;assembly=Dragablz"
xmlns:controls="clr-namespace:Tango.SharedUI.Controls;assembly=Tango.SharedUI"
xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes"
+ xmlns:i="clr-namespace:System.Windows.Interactivity;assembly=System.Windows.Interactivity"
xmlns:managers="clr-namespace:Tango.MachineStudio.DB.Managers"
xmlns:local="clr-namespace:Tango.MachineStudio.DB.Views"
mc:Ignorable="d"
d:DesignHeight="720" d:DesignWidth="1270" Background="White" DataContext="{Binding MainViewVM, Source={StaticResource Locator}}">
<Grid>
- <DockPanel>
- <Grid>
- <Grid>
- <Grid>
- <Grid>
- <Grid.RowDefinitions>
- <RowDefinition Height="Auto"/>
- <RowDefinition Height="1*"/>
- </Grid.RowDefinitions>
+ <Grid>
+ <Grid.ColumnDefinitions>
+ <ColumnDefinition Width="200"/>
+ <ColumnDefinition Width="486*"/>
+ </Grid.ColumnDefinitions>
- <Grid>
- <Menu IsMainMenu="True">
- <MenuItem Header="DataBase" ItemsSource="{x:Static managers:ViewsManager.DbViews}" DisplayMemberPath="Header">
- <MenuItem.ItemContainerStyle>
- <Style TargetType="MenuItem" BasedOn="{StaticResource {x:Type MenuItem}}">
- <Setter Property="Command" Value="{Binding AddCommand}"></Setter>
- </Style>
- </MenuItem.ItemContainerStyle>
- </MenuItem>
- <MenuItem Header="Edit"></MenuItem>
- </Menu>
- </Grid>
+ <Border Background="{StaticResource AccentColorBrush}" Margin="5" CornerRadius="5">
+ <ListBox ItemsSource="{x:Static managers:ViewsManager.DbViews}" Foreground="White" HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch">
+ <ListBox.ItemTemplate>
+ <DataTemplate>
+ <DockPanel LastChildFill="False" Background="Transparent" >
+ <i:Interaction.Triggers>
+ <i:EventTrigger EventName="MouseDown">
+ <i:InvokeCommandAction Command="{Binding AddCommand}"></i:InvokeCommandAction>
+ </i:EventTrigger>
+ </i:Interaction.Triggers>
+ <StackPanel Orientation="Horizontal" DockPanel.Dock="Left">
+ <materialDesign:PackIcon Kind="Table" Width="24" Height="24"></materialDesign:PackIcon>
+ <TextBlock Margin="5 0 0 0" Style="{StaticResource MaterialDesignBody2TextBlock}" VerticalAlignment="Center" Text="{Binding Header}" Background="Transparent" HorizontalAlignment="Stretch"></TextBlock>
+ </StackPanel>
+ <materialDesign:PackIcon ToolTip="View Table" VerticalAlignment="Center" DockPanel.Dock="Right" Kind="ArrowRight"></materialDesign:PackIcon>
+ </DockPanel>
+ </DataTemplate>
+ </ListBox.ItemTemplate>
+ </ListBox>
+ </Border>
- <dockablz:Layout Grid.Row="1" ScrollViewer.VerticalScrollBarVisibility="Visible" ScrollViewer.HorizontalScrollBarVisibility="Visible" FloatingItemsSource="{x:Static managers:ViewsManager.DisplayedViews}" FloatingItemDisplayMemberPath="View" FloatingItemHeaderMemberPath="Header">
+ <Grid Grid.Column="1">
+ <Grid.Background>
+ <ImageBrush ImageSource="../Images/seamless-grid.jpg" Stretch="None" TileMode="Tile" ViewportUnits="Absolute" Viewport="0,0,32,32"></ImageBrush>
+ </Grid.Background>
+ <dockablz:Layout ScrollViewer.VerticalScrollBarVisibility="Visible" ScrollViewer.HorizontalScrollBarVisibility="Visible" FloatingItemsSource="{x:Static managers:ViewsManager.DisplayedViews}" FloatingItemDisplayMemberPath="View" FloatingItemHeaderMemberPath="Header">
- </dockablz:Layout>
-
- <!--<dragablz:TabablzControl BorderThickness="0" FontSize="14" ItemContainerStyle="{DynamicResource TabItemStyle}">
- <dragablz:TabablzControl.Resources>
- <Style x:Key="TabItemStyle" TargetType="{x:Type dragablz:DragablzItem}" BasedOn="{StaticResource MaterialDesignDragableTabItemStyle}">
- <Setter Property="Height" Value="60" />
- <Setter Property="Padding" Value="24,0,24,0" />
- </Style>
- </dragablz:TabablzControl.Resources>
- <dragablz:TabablzControl.InterTabController>
- <dragablz:InterTabController />
- </dragablz:TabablzControl.InterTabController>
- <TabItem Header="ORGANIZATIONS">
- <local:OrganizationsView></local:OrganizationsView>
- </TabItem>
- <TabItem Header="MACHINES">
- <local:MachinesView></local:MachinesView>
- </TabItem>
- <TabItem Header="ADDRESSES">
- <local:AddressesView></local:AddressesView>
- </TabItem>
- <TabItem Header="DISPENSERS">
- <TextBlock HorizontalAlignment="Center" VerticalAlignment="Center">Looks Quite Nice</TextBlock>
- </TabItem>
- <TabItem Header="MEDIA LIST">
- <TextBlock HorizontalAlignment="Center" VerticalAlignment="Center">Looks Quite Nice</TextBlock>
- </TabItem>
- </dragablz:TabablzControl>-->
- </Grid>
- </Grid>
- </Grid>
- </Grid>
- </DockPanel>
+ </dockablz:Layout>
+ </Grid>
+ </Grid>
</Grid>
</UserControl>