Add a confirm dialog box before deleting an annotation by drag and drop. Now the UserControlClose is a generic confirm dialog box sending a ConfirmYesOrNo Event.
<UserControl
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"
mc:Ignorable="d"
x:Class="FingersDance.Control.Close.UserControlClose"
Width="Auto" Height="100" MinWidth="250" xmlns:Custom="http://schemas.microsoft.com/surface/2008" BorderBrush="White" x:Name="myUC">
<UserControl.Background>
<SolidColorBrush Color="Black" Opacity="0.8"/>
</UserControl.Background>
<Grid x:Name="LayoutRoot" >
<TextBlock Margin="10,5,10,43" Text="{Binding Path=Question, ElementName=myUC}" Foreground="White"
FontSize="18" TextWrapping="Wrap"></TextBlock>
<Custom:SurfaceButton Content="Oui" Margin="35,63,0,0" x:Name="SurfaceButtonOK" HorizontalAlignment="Left" Width="85" ContactDown="SurfaceButtonOK_ContactDown" Click="SurfaceButtonOK_Click" Height="30" VerticalAlignment="Top" />
<Custom:SurfaceButton VerticalAlignment="Top" Content="Non" Margin="0,63,28,0" x:Name="SurfaceButtonNO" ContactDown="SurfaceButtonNO_ContactDown" Click="SurfaceButtonNO_Click" Height="30" HorizontalAlignment="Right" Width="85" />
</Grid>
</UserControl>