diff --git a/Modèle/Carte.cs b/Modèle/Carte.cs new file mode 100644 index 0000000..197f7b4 --- /dev/null +++ b/Modèle/Carte.cs @@ -0,0 +1,17 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace WpfApp1 +{ + class Carte + { + public string Nom { get; private set; } + public string Url { get; private set; } + public List LaZone { get; private set; } + + } + +} diff --git a/Modèle/Conservation.cs b/Modèle/Conservation.cs new file mode 100644 index 0000000..2ec65a1 --- /dev/null +++ b/Modèle/Conservation.cs @@ -0,0 +1,21 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace WpfApp1 +{ + enum Conservation + { + EX, + EW, + CR, + EN, + VU, + NT, + LC, + DD, + NE + } +} diff --git a/Modèle/Modèle.csproj b/Modèle/Modèle.csproj new file mode 100644 index 0000000..f208d30 --- /dev/null +++ b/Modèle/Modèle.csproj @@ -0,0 +1,7 @@ + + + + net5.0 + + + diff --git a/Modèle/Requin.cs b/Modèle/Requin.cs new file mode 100644 index 0000000..fa43b01 --- /dev/null +++ b/Modèle/Requin.cs @@ -0,0 +1,49 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace WpfApp1 +{ + class Requin + { + public string Nom { get; private set; } + public string NomSci { get; private set; } + public string Description { get; private set; } + public string Photo { get; private set; } + public string Video { get; private set; } + public Carte PhotoCarte { get; private set; } + public Conservation StatutCons { get; private set; } + public string FunFact { get; private set; } + public Zone Repartition { get; private set; } + + + public Requin(string nom, string nomSci, string description, string photo, string video, Carte photoCarte, Conservation statutCons, Zone repartition, string funFact) { + Nom = nom; + NomSci = nomSci; + Description = description; + Photo = photo; + Video = video; + PhotoCarte = photoCarte; + StatutCons = statutCons; + Repartition = repartition; + FunFact = funFact; + } + + public Requin(string nom, string nomSci, string description, string photo, string video, Carte photoCarte, Conservation statutCons, Zone repartition, List funFacts) + { + Random rnd = new Random(); + Nom = nom; + NomSci = nomSci; + Description = description; + Photo = photo; + Video = video; + PhotoCarte = photoCarte; + StatutCons = statutCons; + Repartition = repartition; + + } + } + +} diff --git a/Modèle/Zone.cs b/Modèle/Zone.cs new file mode 100644 index 0000000..ea9f64c --- /dev/null +++ b/Modèle/Zone.cs @@ -0,0 +1,16 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace WpfApp1 +{ + enum Zone + { + ATLANTIQUE, + ARCTIQUE, + PACIFIQUE, + INDIEN + } +} diff --git a/WpfApp1.sln b/WpfApp1.sln index 762a4fe..8163fcb 100644 --- a/WpfApp1.sln +++ b/WpfApp1.sln @@ -4,12 +4,17 @@ Microsoft Visual Studio Solution File, Format Version 12.00 VisualStudioVersion = 16.0.31424.327 MinimumVisualStudioVersion = 10.0.40219.1 Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "WpfApp1", "WpfApp1\WpfApp1.csproj", "{514D830F-CCD6-4ADE-96F2-232C718D9BBC}" + ProjectSection(ProjectDependencies) = postProject + {006E8327-215C-46B4-8816-24B996B82798} = {006E8327-215C-46B4-8816-24B996B82798} + EndProjectSection EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Dossier1", "Dossier1", "{2FC31FB4-7243-43F2-86EF-BD66C3B0B0CD}" EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Ressources", "Ressources\Ressources.csproj", "{DA0ADA06-41C5-4DA6-8DE6-630CD98E254F}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "testImage", "testImage\testImage.csproj", "{C85454C4-850B-4305-AFB6-789DDA8CD88A}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "testImage", "testImage\testImage.csproj", "{C85454C4-850B-4305-AFB6-789DDA8CD88A}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Modèle", "Modèle\Modèle.csproj", "{006E8327-215C-46B4-8816-24B996B82798}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution @@ -29,6 +34,10 @@ Global {C85454C4-850B-4305-AFB6-789DDA8CD88A}.Debug|Any CPU.Build.0 = Debug|Any CPU {C85454C4-850B-4305-AFB6-789DDA8CD88A}.Release|Any CPU.ActiveCfg = Release|Any CPU {C85454C4-850B-4305-AFB6-789DDA8CD88A}.Release|Any CPU.Build.0 = Release|Any CPU + {006E8327-215C-46B4-8816-24B996B82798}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {006E8327-215C-46B4-8816-24B996B82798}.Debug|Any CPU.Build.0 = Debug|Any CPU + {006E8327-215C-46B4-8816-24B996B82798}.Release|Any CPU.ActiveCfg = Release|Any CPU + {006E8327-215C-46B4-8816-24B996B82798}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE diff --git a/WpfApp1/Conservation.cs b/WpfApp1/Conservation.cs new file mode 100644 index 0000000..2ec65a1 --- /dev/null +++ b/WpfApp1/Conservation.cs @@ -0,0 +1,21 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace WpfApp1 +{ + enum Conservation + { + EX, + EW, + CR, + EN, + VU, + NT, + LC, + DD, + NE + } +} diff --git a/WpfApp1/MainWindow.xaml b/WpfApp1/MainWindow.xaml index 398f0a1..0806903 100644 --- a/WpfApp1/MainWindow.xaml +++ b/WpfApp1/MainWindow.xaml @@ -8,33 +8,35 @@ Title="MainWindow" Height="450" Width="800"> - - - Tous - Arctique - Atlantique - Indien - Pacifique - - - - - - - - - - - - - - + + + Tous + Arctique + Atlantique + Indien + Pacifique + + + + + + + + + + + + + + + + - + diff --git a/WpfApp1/UserControlRequin.xaml b/WpfApp1/UserControlRequin.xaml index b2c63b7..247a80b 100644 --- a/WpfApp1/UserControlRequin.xaml +++ b/WpfApp1/UserControlRequin.xaml @@ -7,21 +7,21 @@ mc:Ignorable="d" d:DesignHeight="450" d:DesignWidth="800" MouseDown="UserControlReq_MouseDown"> - - + + - - + + + - - - + + - - - + + + diff --git a/WpfApp1/userControlDescription.xaml b/WpfApp1/userControlDescription.xaml index 11f3cd1..b7049f8 100644 --- a/WpfApp1/userControlDescription.xaml +++ b/WpfApp1/userControlDescription.xaml @@ -15,16 +15,16 @@ - + - + - - + +