master
Cedric CHARBONNEL 2 years ago
parent 12836f886e
commit f0e77b1e09

@ -4,11 +4,12 @@
xmlns="http://schemas.microsoft.com/dotnet/2021/maui" xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml" xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
xmlns:local="clr-namespace:LOLAPP" xmlns:local="clr-namespace:LOLAPP"
xmlns:view="clr-namespace:LOLAPP.View"
Shell.FlyoutBehavior="Disabled"> Shell.FlyoutBehavior="Disabled">
<TabBar>
<ShellContent <ShellContent
Title="Home" Title="Home"
ContentTemplate="{DataTemplate local:MainPage}" ContentTemplate="{DataTemplate view:Main}"
Route="MainPage" /> Route="MainPage" />
</TabBar>
</Shell> </Shell>

@ -52,4 +52,16 @@
<PackageReference Include="Microsoft.Extensions.Logging.Debug" Version="7.0.0" /> <PackageReference Include="Microsoft.Extensions.Logging.Debug" Version="7.0.0" />
</ItemGroup> </ItemGroup>
<ItemGroup>
<MauiXaml Update="View\Main.xaml">
<Generator>MSBuild:Compile</Generator>
</MauiXaml>
<MauiXaml Update="View\Register.xaml">
<Generator>MSBuild:Compile</Generator>
</MauiXaml>
<MauiXaml Update="View\Strat.xaml">
<Generator>MSBuild:Compile</Generator>
</MauiXaml>
</ItemGroup>
</Project> </Project>

@ -1,50 +0,0 @@
<?xml version="1.0" encoding="utf-8" ?>
<ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
xmlns:model="clr-namespace:LOLAPP.Modele"
x:Class="LOLAPP.MainPage">
<ContentPage.BindingContext>
<model:Manager/>
</ContentPage.BindingContext>
<VerticalStackLayout
Spacing="25"
Padding="30,0"
VerticalOptions="Center">
<ListView x:Name="champ">
<ListView.ItemTemplate>
<DataTemplate>
<ViewCell>
<Border Stroke="DarkSalmon" StrokeThickness="4"
Margin="0, 4" Padding="8,4"
BackgroundColor="GhostWhite">
<Border.StrokeShape>
<RoundRectangle CornerRadius="30, 30, 30, 0"/>
</Border.StrokeShape>
<Grid ColumnDefinitions="Auto, *" RowDefinitions="2*, *, *"
ColumnSpacing="15">
<Frame Grid.RowSpan="3"
WidthRequest="60" HeightRequest="60"
Padding="0" CornerRadius="30" Margin="0"
IsClippedToBounds="True"
BorderColor="DarkSalmon" HasShadow="True" >
<Frame.Shadow>
<Shadow Brush="DarkSalmon" Offset="3, 2"
Radius="2" Opacity="0.8"/>
</Frame.Shadow>
</Frame>
<Label Text="{Binding Name}" Grid.Column="1" FontSize="Medium"/>
</Grid>
</Border>
</ViewCell>
</DataTemplate>
</ListView.ItemTemplate>
</ListView>
<Label Text="{Binding _champions[1].Name}"/>
</VerticalStackLayout>
</ContentPage>

@ -1,16 +0,0 @@
using LOLAPP.Modele;
namespace LOLAPP;
public partial class MainPage : ContentPage
{
int count = 0;
public Manager Cmanager => (App.Current as App).ChampionManager;
public MainPage()
{
InitializeComponent();
BindingContext = Cmanager;
champ.BindingContext = Cmanager._champions;
}
}

@ -0,0 +1,31 @@
<?xml version="1.0" encoding="utf-8" ?>
<ContentPage
xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
x:Class="LOLAPP.View.Main"
Title="Main">
<StackLayout>
<!-- Barre de navigation -->
<StackLayout Orientation="Horizontal" Background="LightGray">
<!-- Image à gauche (redirection vers cette page) -->
<ImageButton Source="CheminVersVotreImage"/>
<!-- Bouton "Strat" à droite de l'image (redirection vers la page "strat") -->
<Button Clicked="StratClick" Text="Strat" />
<!-- Bouton "Register" -->
<Button Clicked="RegisterClick" Text="Register"/>
<!-- Bouton "Login" -->
<Button Clicked="LoginClick" Text="Login"/>
</StackLayout>
<!-- Grille d'images avec fenêtres contextuelles -->
<Grid Grid.Row="1" Margin="10">
<!-- Images -->
<Image Source="CheminVersImage1" Grid.Row="0" Grid.Column="0" />
<Image Source="CheminVersImage2" Grid.Row="0" Grid.Column="1" />
<!-- ... -->
</Grid>
</StackLayout>
</ContentPage>

@ -0,0 +1,20 @@
namespace LOLAPP.View;
public partial class Main : ContentPage
{
public Main()
{
InitializeComponent();
}
private void StratClick(object sender, EventArgs e)
{
}
void RegisterClick(object sender, EventArgs e)
{
}
void LoginClick(object sender, EventArgs e)
{
}
}

@ -0,0 +1,12 @@
<?xml version="1.0" encoding="utf-8" ?>
<ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
x:Class="LOLAPP.View.Register"
Title="Register">
<VerticalStackLayout>
<Label
Text="Welcome to .NET MAUI!"
VerticalOptions="Center"
HorizontalOptions="Center" />
</VerticalStackLayout>
</ContentPage>

@ -0,0 +1,9 @@
namespace LOLAPP.View;
public partial class Register : ContentPage
{
public Register()
{
InitializeComponent();
}
}

@ -0,0 +1,12 @@
<?xml version="1.0" encoding="utf-8" ?>
<ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
x:Class="LOLAPP.View.Strat"
Title="Strat">
<VerticalStackLayout>
<Label
Text="Welcome to .NET MAUI!"
VerticalOptions="Center"
HorizontalOptions="Center" />
</VerticalStackLayout>
</ContentPage>

@ -0,0 +1,9 @@
namespace LOLAPP.View;
public partial class Strat : ContentPage
{
public Strat()
{
InitializeComponent();
}
}
Loading…
Cancel
Save