You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
41 lines
1.1 KiB
41 lines
1.1 KiB
using Models;
|
|
using ShoopNCook.Controllers;
|
|
|
|
namespace ShoopNCook.Pages;
|
|
|
|
public partial class MorePage : ContentPage
|
|
{
|
|
|
|
private readonly MorePageController controller;
|
|
|
|
public MorePage(Account account, MorePageController controller)
|
|
{
|
|
InitializeComponent();
|
|
ProfileImage.Source = ImageSource.FromUri(account.User.ProfilePicture);
|
|
ProfileName.Text = account.User.Name;
|
|
this.controller = controller;
|
|
}
|
|
|
|
private void OnMyRecipesButtonTapped(object sender, EventArgs e)
|
|
{
|
|
controller.GoToMyRecipesPage();
|
|
}
|
|
|
|
private void OnEditProfileButtonTapped(object sender, EventArgs e)
|
|
{
|
|
controller.GoToProfilePage();
|
|
}
|
|
|
|
private void OnLogoutButtonTapped(object sender, EventArgs e)
|
|
{
|
|
controller.Logout();
|
|
}
|
|
private async void OnShareButtonClicked(object sender, EventArgs e)
|
|
{
|
|
await Share.RequestAsync(new ShareTextRequest
|
|
{
|
|
Text = "Voici le texte à partager (à changer)",
|
|
Title = "Partagez ce texte : (à modifier)"
|
|
});
|
|
}
|
|
} |