Mathilde JEAN 3 years ago
commit 4595abe14b

@ -175,9 +175,9 @@
"font": "Arial;13;1",
"left": 341,
"top": 262,
"width": 59.99169921875,
"width": 67.1708984375,
"height": 13,
"text": "test"
"text": "testRequin"
},
{
"_type": "LabelView",
@ -210,7 +210,7 @@
"font": "Arial;13;0",
"left": 336,
"top": 255,
"width": 69.99169921875,
"width": 77.1708984375,
"height": 25,
"stereotypeLabel": {
"$ref": "AAAAAAGAVgJ23UuCE6k="
@ -230,7 +230,7 @@
"containerChangeable": true,
"left": 336,
"top": 240,
"width": 69.99169921875,
"width": 77.1708984375,
"height": 40,
"nameCompartment": {
"$ref": "AAAAAAGAVgJ23EuBaSg="
@ -346,7 +346,7 @@
"_parent": {
"$ref": "AAAAAAGAVgHH+ks1lEI="
},
"name": "test",
"name": "testRequin",
"ownedElements": [
{
"_type": "UMLDependency",

@ -0,0 +1,12 @@
<Window x:Class="WpfApp1.CreerCompte"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:local="clr-namespace:WpfApp1"
mc:Ignorable="d"
Title="CreerCompte" Height="450" Width="800">
<Grid>
</Grid>
</Window>

@ -0,0 +1,27 @@
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.Shapes;
namespace WpfApp1
{
/// <summary>
/// Logique d'interaction pour CreerCompte.xaml
/// </summary>
public partial class CreerCompte : Window
{
public CreerCompte()
{
InitializeComponent();
}
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 62 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 60 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 61 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 61 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 7.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 61 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 58 KiB

Binary file not shown.

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.5 KiB

@ -32,7 +32,7 @@
</DockPanel>
<DockPanel>
<ContentControl x:Name="contentControl">
<local:userControlEdit/>
<local:userControlAcceuil/>
</ContentControl>
</DockPanel>
</DockPanel>

@ -1,4 +1,5 @@
using System;
using Modèle;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
@ -26,6 +27,8 @@ namespace WpfApp1
}
Requin requin { get; set; }
private void ComboBox_SelectionChanged(object sender, SelectionChangedEventArgs e)
{
if (Tous.IsSelected)
@ -35,20 +38,20 @@ namespace WpfApp1
public void ContentControlSwapDes()
{
contentControl.Content = new userControlDescription();
contentControl.Content = new userControlDescription(requin);
}
public void ContentControlSwapAcc()
{
contentControl.Content = new userControlEdit();
contentControl.Content = new userControlAcceuil();
}
public void ContentControlSwapEdit()
public void ContentControlSwapEdit(Requin requin)
{
contentControl.Content = new userControlEdit();
contentControl.Content = new UserControlEdit(requin);
}
private void TextBox_IsKeyboardFocusedChanged(object sender, DependencyPropertyChangedEventArgs e)

@ -0,0 +1,12 @@
<Window x:Class="WpfApp1.SeConnecter"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:local="clr-namespace:WpfApp1"
mc:Ignorable="d"
Title="SeConnecter" Height="450" Width="800">
<Grid>
</Grid>
</Window>

@ -0,0 +1,27 @@
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.Shapes;
namespace WpfApp1
{
/// <summary>
/// Logique d'interaction pour SeConnecter.xaml
/// </summary>
public partial class SeConnecter : Window
{
public SeConnecter()
{
InitializeComponent();
}
}
}

@ -9,7 +9,7 @@
<DockPanel>
<DockPanel x:Name="Button" DockPanel.Dock="Top">
<TextBlock Text="EDIT A SHARK" HorizontalAlignment="Center" VerticalAlignment="Center" Margin="20" FontSize="30" FontWeight="Bold" FontFamily="Candara Light" Foreground="{StaticResource Couleur2}"/>
<Button x:Name="add" Style="{StaticResource Button1}" HorizontalAlignment="Right" VerticalAlignment="Center" Content="x" Width="50" Height="50" FontSize="25"></Button>
<Button x:Name="exit" Style="{StaticResource Button1}" HorizontalAlignment="Right" VerticalAlignment="Center" Content="x" Width="50" Height="50" FontSize="25" Click="exit_Click"></Button>
</DockPanel>
<DockPanel Background="{StaticResource Couleur1}">
<TextBlock DockPanel.Dock="Top" Text="Shark information :" Margin="15" FontSize="18" Foreground="{StaticResource Couleur3}"/>
@ -25,10 +25,11 @@
<RowDefinition/>
<RowDefinition/>
</Grid.RowDefinitions>
<local:UserControlBoite Grid.Column="0" Grid.Row="0" Message="Nom" x:Name="leNom" Contenu="Nom Du Requin" IsKeyboardFocusedChanged="leNom_IsKeyboardFocusedChanged" IsEnabledChanged="False"/>
<local:UserControlBoite Grid.Column="0" Grid.Row="1" Message="Nom scientifique" x:Name="nomSci" Contenu="" IsKeyboardFocusedChanged="nomSci_IsKeyboardFocusedChanged"/>
<local:UserControlBoite Grid.Column="0" Grid.Row="2" Message="Lien de la photo" x:Name="LienPhoto" Contenu="" IsKeyboardFocusedChanged="LienPhoto_IsKeyboardFocusedChanged"/>
<local:UserControlBoite Grid.Column="0" Grid.Row="3" Message="Lien de la vidéo" x:Name="LienVid" Contenu="" IsKeyboardFocusedChanged="LienVid_IsKeyboardFocusedChanged"/>
<local:UserControlBoite Grid.Column="0" Grid.Row="0" Message="Nom" x:Name="leNom" Contenu="" IsEnabledChanged="False"/>
<local:UserControlBoite Grid.Column="0" Grid.Row="1" Message="Nom scientifique" x:Name="nomSci" Contenu="" IsEnabledChanged="False"/>
<local:UserControlBoite Grid.Column="0" Grid.Row="2" Message="Description" x:Name="desc" Contenu="" IsEnabledChanged="" IsKeyboardFocusedChanged="desc_IsKeyboardFocusedChanged"/>
<local:UserControlBoite Grid.Column="0" Grid.Row="3" Message="Lien de la photo" x:Name="LienPhoto" Contenu="" IsKeyboardFocusedChanged="LienPhoto_IsKeyboardFocusedChanged"/>
<local:UserControlBoite Grid.Column="0" Grid.Row="4" Message="Lien de la vidéo" x:Name="LienVid" Contenu="" IsKeyboardFocusedChanged="LienVid_IsKeyboardFocusedChanged"/>
<local:UserControlBoite Grid.Column="1" Grid.Row="0" Message="Lien de la map" x:Name="LienMap" Contenu="" IsKeyboardFocusedChanged="LienMap_IsKeyboardFocusedChanged"/>
<local:UserControlBoite Grid.Column="1" Grid.Row="1" Message="Fun fact (optionnel)" x:Name="funFact" Contenu="" IsKeyboardFocusedChanged="funFact_IsKeyboardFocusedChanged"/>
<Grid Grid.Column="1" Grid.Row="2" ShowGridLines="True" Width="320" Height="19" VerticalAlignment="Top" Background="{StaticResource Couleur2}">
@ -84,7 +85,7 @@
<RadioButton Style="{StaticResource RadioGaga}" Content="NE" Grid.Column="3" Grid.Row="1"/>
</Grid>
<Button Style="{StaticResource Button1}" Grid.Column="1" Grid.Row="5" Content="Submit" Margin="15" Width="100"/>
<Button Style="{StaticResource Button1}" Grid.Column="1" Grid.Row="4" Content="Submit" Margin="15" Width="100"/>
</Grid>
</DockPanel>
</DockPanel>

@ -21,10 +21,10 @@ namespace WpfApp1
/// </summary>
public partial class UserControlEdit : UserControl
{
public UserControlEdit()
public UserControlEdit(Requin requin)
{
InitializeComponent();
uptadeUi(requin);
}
public Requin requin { get; set; }
@ -34,16 +34,6 @@ namespace WpfApp1
LienPhoto.Contenu = "";
}
private void leNom_IsKeyboardFocusedChanged(object sender, DependencyPropertyChangedEventArgs e)
{
leNom.Contenu = "";
}
private void nomSci_IsKeyboardFocusedChanged(object sender, DependencyPropertyChangedEventArgs e)
{
sciName = "";
}
private void LienVid_IsKeyboardFocusedChanged(object sender, DependencyPropertyChangedEventArgs e)
{
LienVid.Contenu = "";
@ -58,5 +48,25 @@ namespace WpfApp1
{
funFact.Contenu = "";
}
private void desc_IsKeyboardFocusedChanged(object sender, DependencyPropertyChangedEventArgs e)
{
desc.Contenu = "";
}
public void uptadeUi(Requin requin)
{
leNom.Contenu = requin.Nom;
nomSci.Contenu = requin.NomSci;
desc.Contenu = requin.Description;
LienPhoto.Contenu = requin.Photo;
LienVid.Contenu = requin.Video;
LienMap.Contenu = requin.PhotoCarte;
funFact.Contenu = requin.FunFact;
}
private void exit_Click(object sender, RoutedEventArgs e)
{
((MainWindow)System.Windows.Application.Current.MainWindow).ContentControlSwapAcc();
}
}
}

@ -10,14 +10,22 @@
<None Remove="Images\carte.png" />
<None Remove="Images\cartemaismieux.png" />
<None Remove="Images\cartemaismieuxman.png" />
<None Remove="Images\CR.png" />
<None Remove="Images\cross.png" />
<None Remove="Images\Donnees insuffisantes.png" />
<None Remove="Images\DD.png" />
<None Remove="Images\En-danger.png" />
<None Remove="Images\EN.png" />
<None Remove="Images\EW.png" />
<None Remove="Images\EX.png" />
<None Remove="Images\Heterodontus_francisci_catalina.jpg" />
<None Remove="Images\LC.png" />
<None Remove="Images\logo.png" />
<None Remove="Images\Logo_entier.png" />
<None Remove="Images\NE.png" />
<None Remove="Images\NT.png" />
<None Remove="Images\plus.png" />
<None Remove="Images\rep_Heterodontus_mexicanus.png" />
<None Remove="Images\VU.png" />
<None Remove="Videos\Vid-dormeur-mexicain.mp4" />
</ItemGroup>
@ -38,10 +46,16 @@
<Content Include="Images\cross.png">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</Content>
<Content Include="Images\Donnees insuffisantes.png">
<Content Include="Images\En-danger.png">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</Content>
<Content Include="Images\En-danger.png">
<Content Include="Images\LC.png">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</Content>
<Content Include="Images\NE.png">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</Content>
<Content Include="Images\NT.png">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</Content>
<Content Include="Images\plus.png">
@ -50,6 +64,9 @@
<Content Include="Images\rep_Heterodontus_mexicanus.png">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</Content>
<Content Include="Images\VU.png">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</Content>
<Content Include="Videos\Vid-dormeur-mexicain.mp4">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</Content>
@ -67,6 +84,21 @@
</ItemGroup>
<ItemGroup>
<Content Include="Images\CR.png">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</Content>
<Content Include="Images\DD.png">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</Content>
<Content Include="Images\EN.png">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</Content>
<Content Include="Images\EW.png">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</Content>
<Content Include="Images\EX.png">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</Content>
<Resource Include="Images\logo.png" />
<Resource Include="Images\Logo_entier.png" />
</ItemGroup>

@ -1,4 +1,4 @@
<UserControl x:Class="WpfApp1.userControlEdit"
<UserControl x:Class="WpfApp1.userControlAcceuil"
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"

@ -18,9 +18,9 @@ namespace WpfApp1
/// <summary>
/// Logique d'interaction pour userControlAcceuil.xaml
/// </summary>
public partial class userControlEdit : UserControl
public partial class userControlAcceuil : UserControl
{
public userControlEdit()
public userControlAcceuil()
{
InitializeComponent();
}

@ -51,7 +51,7 @@ Il y a très peu d'information sur les effectifs de cette espèce, mais sa situa
</DockPanel>
<DockPanel Background="{StaticResource Couleur3}" DockPanel.Dock="Right">
<Image Source="Images\rep_Heterodontus_mexicanus.png" Margin="0,25,0,20" DockPanel.Dock="Top" MinHeight="50" MaxHeight="125" HorizontalAlignment="Center" x:Name="cartePic"></Image>
<Image Source="Images\Donnees insuffisantes.png" Margin="15,5,5,5" DockPanel.Dock="Top" HorizontalAlignment="Center" MinHeight="5" MaxHeight="25" x:Name="consPic" ></Image>
<Image Source="Images\DD.png" Margin="15,5,5,5" DockPanel.Dock="Top" HorizontalAlignment="Center" MinHeight="5" MaxHeight="60" x:Name="consPic" ></Image>
<TextBlock Text="Fun fact" FontSize="20" DockPanel.Dock="Top" HorizontalAlignment="Center" Margin="0,15,0,0" Foreground="{StaticResource Couleur1}" FontFamily="{StaticResource Police2}" ></TextBlock>
<TextBlock Text="La bouche du requin dormeur mexicain est en forme de museau de cochon !" FontSize="12" DockPanel.Dock="Bottom" TextWrapping="Wrap" Foreground="{StaticResource Couleur1}" Margin="0,5,0,0" TextAlignment="Center" HorizontalAlignment="Center" Width="175" x:Name="funFact"></TextBlock>
</DockPanel>

@ -21,9 +21,10 @@ namespace WpfApp1
/// </summary>
public partial class userControlDescription : UserControl
{
public userControlDescription()
public userControlDescription(Requin requin)
{
InitializeComponent();
UpdateUI(requin);
}
public Requin Requin { get; set; }
@ -35,7 +36,23 @@ namespace WpfApp1
private void edit_Click(object sender, RoutedEventArgs e)
{
((MainWindow)System.Windows.Application.Current.MainWindow).ContentControlSwapEdit();
((MainWindow)System.Windows.Application.Current.MainWindow).ContentControlSwapEdit(requin);
}
public Requin requin { get; set; }
public void UpdateUI(Requin requin)
{
string url = "/Images/" + requin.StatutCons.ToString() + ".png";
nameReq.Text = requin.Nom;
sciName.Text = requin.NomSci;
desc.Text = requin.Description;
vid.Source = new Uri(requin.Video);
photo.Source = new BitmapImage(new Uri(requin.Photo, UriKind.Relative));
funFact.Text = requin.FunFact;
consPic.Source = new BitmapImage(new Uri(url, UriKind.Relative));
cartePic.Source = new BitmapImage(new Uri(requin.PhotoCarte, UriKind.Relative));
}
public void uptadeUi(Requin requin)

Loading…
Cancel
Save