├── DesktopWindowDemo ├── Assets │ ├── WinUI3.ico │ ├── StoreLogo.png │ ├── SplashScreen.scale-200.png │ ├── LockScreenLogo.scale-200.png │ ├── Square44x44Logo.scale-200.png │ ├── Wide310x150Logo.scale-200.png │ ├── Square150x150Logo.scale-200.png │ └── Square44x44Logo.targetsize-24_altform-unplated.png ├── Properties │ └── launchSettings.json ├── App.xaml ├── app.manifest ├── Package.appxmanifest ├── App.xaml.cs ├── DesktopWindowDemo.csproj ├── MainWindow.xaml └── MainWindow.xaml.cs ├── WindowExtensions ├── WindowExtensions.csproj ├── DisplayInformation.cs └── DesktopWindow.cs ├── .gitattributes ├── DesktopWindowSample.sln ├── README.md └── .gitignore /DesktopWindowDemo/Assets/WinUI3.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/marb2000/DesktopWindow/HEAD/DesktopWindowDemo/Assets/WinUI3.ico -------------------------------------------------------------------------------- /DesktopWindowDemo/Assets/StoreLogo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/marb2000/DesktopWindow/HEAD/DesktopWindowDemo/Assets/StoreLogo.png -------------------------------------------------------------------------------- /DesktopWindowDemo/Assets/SplashScreen.scale-200.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/marb2000/DesktopWindow/HEAD/DesktopWindowDemo/Assets/SplashScreen.scale-200.png -------------------------------------------------------------------------------- /DesktopWindowDemo/Assets/LockScreenLogo.scale-200.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/marb2000/DesktopWindow/HEAD/DesktopWindowDemo/Assets/LockScreenLogo.scale-200.png -------------------------------------------------------------------------------- /DesktopWindowDemo/Assets/Square44x44Logo.scale-200.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/marb2000/DesktopWindow/HEAD/DesktopWindowDemo/Assets/Square44x44Logo.scale-200.png -------------------------------------------------------------------------------- /DesktopWindowDemo/Assets/Wide310x150Logo.scale-200.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/marb2000/DesktopWindow/HEAD/DesktopWindowDemo/Assets/Wide310x150Logo.scale-200.png -------------------------------------------------------------------------------- /DesktopWindowDemo/Assets/Square150x150Logo.scale-200.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/marb2000/DesktopWindow/HEAD/DesktopWindowDemo/Assets/Square150x150Logo.scale-200.png -------------------------------------------------------------------------------- /DesktopWindowDemo/Assets/Square44x44Logo.targetsize-24_altform-unplated.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/marb2000/DesktopWindow/HEAD/DesktopWindowDemo/Assets/Square44x44Logo.targetsize-24_altform-unplated.png -------------------------------------------------------------------------------- /DesktopWindowDemo/Properties/launchSettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "profiles": { 3 | "DesktopWindowDemo (Package)": { 4 | "commandName": "MsixPackage" 5 | }, 6 | "DesktopWindowDemo (Unpackaged)": { 7 | "commandName": "Project" 8 | } 9 | } 10 | } -------------------------------------------------------------------------------- /DesktopWindowDemo/App.xaml: -------------------------------------------------------------------------------- 1 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | -------------------------------------------------------------------------------- /DesktopWindowDemo/app.manifest: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 11 | true/PM 12 | PerMonitorV2, PerMonitor 13 | 14 | 15 | 16 | -------------------------------------------------------------------------------- /WindowExtensions/WindowExtensions.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | net6.0-windows10.0.19041.0 4 | 10.0.17763.0 5 | WindowExtensions 6 | win10-x86;win10-x64;win10-arm64 7 | true 8 | 9 | 10 | 11 | true 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | -------------------------------------------------------------------------------- /DesktopWindowDemo/Package.appxmanifest: -------------------------------------------------------------------------------- 1 | 2 | 3 | 8 | 9 | 13 | 14 | 15 | DesktopWindowDemo 16 | migue 17 | Assets\StoreLogo.png 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 33 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | -------------------------------------------------------------------------------- /DesktopWindowDemo/App.xaml.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.UI.Xaml; 2 | using Microsoft.UI.Xaml.Controls; 3 | using Microsoft.UI.Xaml.Controls.Primitives; 4 | using Microsoft.UI.Xaml.Data; 5 | using Microsoft.UI.Xaml.Input; 6 | using Microsoft.UI.Xaml.Media; 7 | using Microsoft.UI.Xaml.Navigation; 8 | using Microsoft.UI.Xaml.Shapes; 9 | using System; 10 | using System.Collections.Generic; 11 | using System.IO; 12 | using System.Linq; 13 | using System.Runtime.InteropServices.WindowsRuntime; 14 | using Windows.ApplicationModel; 15 | using Windows.ApplicationModel.Activation; 16 | using Windows.Foundation; 17 | using Windows.Foundation.Collections; 18 | 19 | // To learn more about WinUI, the WinUI project structure, 20 | // and more about our project templates, see: http://aka.ms/winui-project-info. 21 | 22 | namespace DesktopWindowDemo 23 | { 24 | /// 25 | /// Provides application-specific behavior to supplement the default Application class. 26 | /// 27 | public partial class App : Application 28 | { 29 | /// 30 | /// Initializes the singleton application object. This is the first line of authored code 31 | /// executed, and as such is the logical equivalent of main() or WinMain(). 32 | /// 33 | public App() 34 | { 35 | this.InitializeComponent(); 36 | } 37 | 38 | /// 39 | /// Invoked when the application is launched normally by the end user. Other entry points 40 | /// will be used such as when the application is launched to open a specific file. 41 | /// 42 | /// Details about the launch request and process. 43 | protected override void OnLaunched(Microsoft.UI.Xaml.LaunchActivatedEventArgs args) 44 | { 45 | m_window = new MainWindow(); 46 | m_window.Activate(); 47 | } 48 | 49 | private Window m_window; 50 | } 51 | } 52 | -------------------------------------------------------------------------------- /DesktopWindowDemo/DesktopWindowDemo.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | WinExe 4 | net6.0-windows10.0.19041.0 5 | 10.0.17763.0 6 | DesktopWindowDemo 7 | app.manifest 8 | x86;x64;arm64 9 | win10-x86;win10-x64;win10-arm64 10 | win10-$(Platform).pubxml 11 | true 12 | true 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | -------------------------------------------------------------------------------- /.gitattributes: -------------------------------------------------------------------------------- 1 | ############################################################################### 2 | # Set default behavior to automatically normalize line endings. 3 | ############################################################################### 4 | * text=auto 5 | 6 | ############################################################################### 7 | # Set default behavior for command prompt diff. 8 | # 9 | # This is need for earlier builds of msysgit that does not have it on by 10 | # default for csharp files. 11 | # Note: This is only used by command line 12 | ############################################################################### 13 | #*.cs diff=csharp 14 | 15 | ############################################################################### 16 | # Set the merge driver for project and solution files 17 | # 18 | # Merging from the command prompt will add diff markers to the files if there 19 | # are conflicts (Merging from VS is not affected by the settings below, in VS 20 | # the diff markers are never inserted). Diff markers may cause the following 21 | # file extensions to fail to load in VS. An alternative would be to treat 22 | # these files as binary and thus will always conflict and require user 23 | # intervention with every merge. To do so, just uncomment the entries below 24 | ############################################################################### 25 | #*.sln merge=binary 26 | #*.csproj merge=binary 27 | #*.vbproj merge=binary 28 | #*.vcxproj merge=binary 29 | #*.vcproj merge=binary 30 | #*.dbproj merge=binary 31 | #*.fsproj merge=binary 32 | #*.lsproj merge=binary 33 | #*.wixproj merge=binary 34 | #*.modelproj merge=binary 35 | #*.sqlproj merge=binary 36 | #*.wwaproj merge=binary 37 | 38 | ############################################################################### 39 | # behavior for image files 40 | # 41 | # image files are treated as binary by default. 42 | ############################################################################### 43 | #*.jpg binary 44 | #*.png binary 45 | #*.gif binary 46 | 47 | ############################################################################### 48 | # diff behavior for common document formats 49 | # 50 | # Convert binary document formats to text before diffing them. This feature 51 | # is only available from the command line. Turn it on by uncommenting the 52 | # entries below. 53 | ############################################################################### 54 | #*.doc diff=astextplain 55 | #*.DOC diff=astextplain 56 | #*.docx diff=astextplain 57 | #*.DOCX diff=astextplain 58 | #*.dot diff=astextplain 59 | #*.DOT diff=astextplain 60 | #*.pdf diff=astextplain 61 | #*.PDF diff=astextplain 62 | #*.rtf diff=astextplain 63 | #*.RTF diff=astextplain 64 | -------------------------------------------------------------------------------- /DesktopWindowDemo/MainWindow.xaml: -------------------------------------------------------------------------------- 1 | 10 | 11 | 12 | 13 | 14 | 15 | 20 | 21 | 23 | 24 | 25 |