forked from dotnet/maui
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
author
committed
Oct 14, 2021
1 parent
919f402
commit 211727e
Showing
8 changed files
with
88 additions
and
64 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
using Foundation; | ||
using AppKit; | ||
using Microsoft.Maui; | ||
using Microsoft.Maui.Hosting; | ||
using Microsoft.Maui.Controls; | ||
|
||
namespace Maui.Controls.Sample.Macos | ||
{ | ||
public class App: Application | ||
{ | ||
public App() | ||
{ | ||
MainPage = new Page(); | ||
} | ||
} | ||
} |
29 changes: 15 additions & 14 deletions
29
src/Controls/samples/Maui.Controls.Sample.Macos/AppDelegate.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,24 +1,25 @@ | ||
using AppKit; | ||
using Foundation; | ||
using Microsoft.Maui; | ||
using Microsoft.Maui.Hosting; | ||
using Microsoft.Maui.Controls; | ||
using Microsoft.Maui.Controls.Hosting; | ||
|
||
namespace Maui.Controls.Sample.Macos | ||
{ | ||
[Register("AppDelegate")] | ||
public class AppDelegate : NSApplicationDelegate | ||
public class AppDelegate : MauiUIApplicationDelegate | ||
{ | ||
public AppDelegate() | ||
{ | ||
} | ||
public AppDelegate() | ||
{ | ||
} | ||
|
||
public override void DidFinishLaunching(NSNotification notification) | ||
{ | ||
// Insert code here to initialize your application | ||
} | ||
|
||
public override void WillTerminate(NSNotification notification) | ||
{ | ||
// Insert code here to tear down your application | ||
} | ||
} | ||
protected override MauiApp CreateMauiApp() | ||
{ | ||
var appBuilder = MauiApp.CreateBuilder(); | ||
appBuilder.UseMauiApp<App>(); | ||
return appBuilder.Build(); | ||
} | ||
} | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters