try NavBar

This commit is contained in:
Natlinux
2022-11-27 15:18:07 +01:00
parent a2c926f915
commit d45c0cc1d5
17 changed files with 69 additions and 122 deletions

View File

@@ -1,4 +1,4 @@
<UserControl x:Class="Apollon.WPF.Views.Components.NavBarView"
<UserControl x:Class="Apollon.WPF.Views.Components.NavBarPreparationView"
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"
@@ -7,7 +7,18 @@
xmlns:iconPacks="http://metro.mahapps.com/winfx/xaml/iconpacks"
mc:Ignorable="d"
d:DesignHeight="450" d:DesignWidth="800">
<Grid>
<Grid>
<StackPanel>
<Button Width="35"
Height="35"
Background="Transparent"
BorderThickness="0"
Command="{Binding NavigateOverviewCommand}">
<iconPacks:PackIconMaterial Kind="ArrowLeft"
Height="25"
Width="35"
Foreground="#0000a0"/>
</Button>
<Menu Height="450"
Background="Transparent"
Margin="0,20,0,0">
@@ -65,7 +76,7 @@
HorizontalAlignment="Center"
VerticalAlignment="Center"/>
</MenuItem.Icon>
</MenuItem>
</MenuItem>
<MenuItem Header="Teilnehmer setzen"
Template="{StaticResource Item_Template}">
<MenuItem.Icon>
@@ -76,7 +87,7 @@
HorizontalAlignment="Center"
VerticalAlignment="Center"/>
</MenuItem.Icon>
</MenuItem>
</MenuItem>
</MenuItem>
<MenuItem Header="Daten"
Template="{StaticResource Menu_SubMenu_Template }"
@@ -362,7 +373,7 @@
</MenuItem.Icon>
</MenuItem>
</MenuItem>
</Menu>
</Menu>
</StackPanel>
</Grid>
</UserControl>

View File

@@ -18,9 +18,9 @@ namespace Apollon.WPF.Views.Components
/// <summary>
/// Interaction logic for NavBarView.xaml
/// </summary>
public partial class NavBarView : UserControl
public partial class NavBarPreparationView : UserControl
{
public NavBarView()
public NavBarPreparationView()
{
InitializeComponent();
}

View File

@@ -289,7 +289,7 @@
Width="150"
Margin="10"
Cursor="Hand"
Command="{Binding NavigateTournamentDetailsCommand}">
Command="{Binding NavigatePreparationCommand}">
<Button.Style>
<Style TargetType="Button" BasedOn="{StaticResource ModernButton}">
<Setter Property="Visibility" Value="Hidden"/>

View File

@@ -3,10 +3,30 @@
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:components="clr-namespace:Apollon.WPF.Views.Components"
xmlns:iconPacks="http://metro.mahapps.com/winfx/xaml/iconpacks"
xmlns:local="clr-namespace:Apollon.WPF.Views"
mc:Ignorable="d"
d:DesignHeight="450" d:DesignWidth="800">
<Grid>
<TextBlock Text="Gruppen" VerticalAlignment="Center" HorizontalAlignment="Center"/>
<Grid Margin="20" >
<Grid.RowDefinitions>
<RowDefinition Height="120"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="250"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Border Grid.Column="2" Grid.Row="2"
BorderBrush="#0000a0"
BorderThickness="1"
CornerRadius="2">
<TextBlock Text="Gruppen" VerticalAlignment="Center" HorizontalAlignment="Center"/>
</Border>
<components:TournamentDetails Grid.Column="1" Margin="0,35,0,10" HorizontalAlignment="Center" DataContext="{Binding TournamentDetailsViewModel}"/>
<components:NavBarPreparationView Grid.Row="1" Margin="0 ,0 ,2, 30"/>
</Grid>
</UserControl>

View File

@@ -61,7 +61,7 @@
Width="210"
Margin="40"
Cursor="Hand"
Command="{Binding AddTournamentCommand}"/>
Command="{Binding OpenAddTournamentCommand}"/>
<Button Style="{StaticResource ModernButton}"
Content="Namenliste pflegen"

View File

@@ -1,40 +0,0 @@
<UserControl x:Class="Apollon.WPF.Views.PreparationView"
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:components="clr-namespace:Apollon.WPF.Views.Components"
xmlns:iconPacks="http://metro.mahapps.com/winfx/xaml/iconpacks"
xmlns:local="clr-namespace:Apollon.WPF.Views"
mc:Ignorable="d">
<Grid Margin="20" >
<Grid.RowDefinitions>
<RowDefinition Height="120"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="250"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Border Grid.Column="2" Grid.Row="2"
BorderBrush="#0000a0"
BorderThickness="1"
CornerRadius="2"></Border>
<Button Width="35"
Height="35"
Background="Transparent"
BorderThickness="0"
HorizontalAlignment="Left"
Margin="5"
Command="{Binding NavigateOverviewCommand}">
<iconPacks:PackIconMaterial Kind="ArrowLeft"
Height="25"
Width="35"
Foreground="#0000a0"/>
</Button>
<components:TournamentDetails Grid.Column="1" Margin="0,35,0,10" HorizontalAlignment="Center" DataContext="{Binding TournamentDetailsViewModel}"/>
<components:NavBarView Grid.Row="1" Margin="0 ,0 ,2, 30"/>
</Grid>
</UserControl>

View File

@@ -1,28 +0,0 @@
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 Apollon.WPF.Views
{
/// <summary>
/// Interaction logic for TournamentDetailsView.xaml
/// </summary>
public partial class PreparationView : UserControl
{
public PreparationView()
{
InitializeComponent();
}
}
}