Skip to content

Commit

Permalink
feat: Add AppWindowPresenter
Browse files Browse the repository at this point in the history
  • Loading branch information
MartinZikmund committed Feb 28, 2024
1 parent 8408032 commit 2485330
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,17 @@
#pragma warning disable 114 // new keyword hiding
namespace Microsoft.UI.Windowing
{
#if __ANDROID__ || __IOS__ || IS_UNIT_TESTS || __WASM__ || __SKIA__ || __NETSTD_REFERENCE__ || __MACOS__
#if false
[global::Uno.NotImplemented]
#endif
public partial class AppWindowPresenter
{
#if __ANDROID__ || __IOS__ || IS_UNIT_TESTS || __WASM__ || __SKIA__ || __NETSTD_REFERENCE__ || __MACOS__
#if false
internal AppWindowPresenter()
{
}
#endif
#if __ANDROID__ || __IOS__ || IS_UNIT_TESTS || __WASM__ || __SKIA__ || __NETSTD_REFERENCE__ || __MACOS__
#if false
[global::Uno.NotImplemented("__ANDROID__", "__IOS__", "IS_UNIT_TESTS", "__WASM__", "__SKIA__", "__NETSTD_REFERENCE__", "__MACOS__")]
public global::Microsoft.UI.Windowing.AppWindowPresenterKind Kind
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
namespace Microsoft.UI.Windowing;

/// <summary>
/// Provides data for the AppWindow.Closing event.
/// </summary>
#if HAS_UNO_WINUI
public
#else
Expand All @@ -11,5 +14,8 @@ internal AppWindowClosingEventArgs()
{
}

/// <summary>
/// Gets or sets a value that indicates whether the event should be canceled.
/// </summary>
public bool Cancel { get; set; }
}
14 changes: 14 additions & 0 deletions src/Uno.UWP/Microsoft/UI/Windowing/AppWindowPresenter.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
namespace Microsoft.UI.Windowing;

public partial class AppWindowPresenter
{
/// <summary>
/// Displays an app window using a pre-defined configuration appropriate for the type of window.
/// </summary>
internal AppWindowPresenter(AppWindowPresenterKind kind) => Kind = kind;

/// <summary>
/// Gets a value that indicates the kind of presenter the app window is using.
/// </summary>
public AppWindowPresenterKind Kind { get; }
}

0 comments on commit 2485330

Please sign in to comment.