parent
f26b307edb
commit
b940af0596
@ -0,0 +1,15 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8" ?>
|
||||||
|
<toolkit:Popup xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
|
||||||
|
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
|
||||||
|
xmlns:toolkit="http://schemas.microsoft.com/dotnet/2022/maui/toolkit"
|
||||||
|
x:Class="Stim.ConfirmationPopup"
|
||||||
|
CanBeDismissedByTappingOutsideOfPopup="False">
|
||||||
|
|
||||||
|
<Grid RowDefinitions="*, *" ColumnDefinitions="*, *">
|
||||||
|
<Label Grid.ColumnSpan="2" x:Name="placeholder" Style="{StaticResource popupLabel}"/>
|
||||||
|
<Button Grid.Row="2" Style="{StaticResource popupButton}" Text="Non" Clicked="No"/>
|
||||||
|
<Button Grid.Row="2" Grid.Column="2" Style="{StaticResource popupButton}" Text="Oui" Clicked="Yes"/>
|
||||||
|
</Grid>
|
||||||
|
</toolkit:Popup>
|
||||||
|
|
||||||
|
|
@ -0,0 +1,17 @@
|
|||||||
|
using CommunityToolkit.Maui.Views;
|
||||||
|
|
||||||
|
namespace Stim;
|
||||||
|
|
||||||
|
public partial class ConfirmationPopup : Popup
|
||||||
|
{
|
||||||
|
public ConfirmationPopup(string message)
|
||||||
|
{
|
||||||
|
InitializeComponent();
|
||||||
|
placeholder.Text = message;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void Yes(object sender, EventArgs e)
|
||||||
|
=> Close(true);
|
||||||
|
public void No(object sender, EventArgs e)
|
||||||
|
=> Close(false);
|
||||||
|
}
|
Loading…
Reference in new issue