From 0f9bcd287ddef8a66b50209e59100131a198184c Mon Sep 17 00:00:00 2001 From: roman Date: Tue, 24 Oct 2023 14:23:01 +0300 Subject: [PATCH] 1.5.1 --- Exmaple2.0/Views/MainWindow.axaml.cs | 2 +- MsBox.Avalonia/Base/IMsBox.cs | 31 ++++++++++++++++++++++++++++ MsBox.Avalonia/MsBox.Avalonia.csproj | 2 +- 3 files changed, 33 insertions(+), 2 deletions(-) diff --git a/Exmaple2.0/Views/MainWindow.axaml.cs b/Exmaple2.0/Views/MainWindow.axaml.cs index 2f35379..149c6f8 100644 --- a/Exmaple2.0/Views/MainWindow.axaml.cs +++ b/Exmaple2.0/Views/MainWindow.axaml.cs @@ -84,7 +84,7 @@ private async void Standard_Popup_OnClick(object sender, RoutedEventArgs e) ShowInCenter = true, Topmost = false }); - + var result = await box.ShowAsPopupAsync(this); } diff --git a/MsBox.Avalonia/Base/IMsBox.cs b/MsBox.Avalonia/Base/IMsBox.cs index 2bf4df8..e9f699a 100644 --- a/MsBox.Avalonia/Base/IMsBox.cs +++ b/MsBox.Avalonia/Base/IMsBox.cs @@ -5,10 +5,41 @@ namespace MsBox.Avalonia.Base; public interface IMsBox { + /// + /// Show messagebox depending on the type of application + /// If application is SingleViewApplicationLifetime (Mobile or Browses) then show messagebox as popup + /// If application is ClassicDesktopStyleApplicationLifetime (Desktop) then show messagebox as window + /// + /// + /// Task ShowAsync(); + + /// + /// Show messagebox as window + /// + /// Task ShowWindowAsync(); + + /// + /// Show messagebox as window with owner + /// + /// Window owner + /// Task ShowWindowDialogAsync(Window owner); + + /// + /// Show messagebox as popup + /// + /// + /// Task ShowAsPopupAsync(ContentControl owner); + + /// + /// Show messagebox as popup with owner + /// + /// + /// Task ShowAsPopupAsync(Window owner); + string InputValue { get; } } \ No newline at end of file diff --git a/MsBox.Avalonia/MsBox.Avalonia.csproj b/MsBox.Avalonia/MsBox.Avalonia.csproj index c30c3f8..b2f4ae5 100644 --- a/MsBox.Avalonia/MsBox.Avalonia.csproj +++ b/MsBox.Avalonia/MsBox.Avalonia.csproj @@ -1,7 +1,7 @@ - 3.1.5 + 3.1.5.1 MessageBox.Avalonia Lary Messagebox for AvaloniaUI