Windows App SDK 1.0.0-Preview2 with Windows styles from WinUI 2.6.

0

Microsoft has just released Windows App SDK 1.0.0-Preview2, a toolkit that enables desktop app developers to build apps with a modern Windows user interface, APIs, and platform features.

SDK version 1.0.0-Preview2 brings the following features and improvements:

WinUI 3

New Updates:

  • The controls have been updated to reflect the latest Windows styles from WinUI 2.6.
  • Single-project MSIX is supported.
  • The WinUI package can now target build 17763 and above. See number 921 for more information.
  • The in-app toolbar is supported. However, the in-app toolbar and existing Hot Reload / Live Visual Tree support require the next release of Visual Studio 17.0 Preview 5, available later in October.

Bug fixed: the WebView2Runtime text is now localized.

Windowing

This release introduces updates to the AppWindow class. There are no major new features added in this release, but changes have been made to method names, properties, and some return values ​​have been removed. See the documentation and samples for detailed updates. If you have worked with AppWindow in versions 1.0 Experimental or 1.0 Preview 1, expect changes to your code.

New Updates:

  • The AppWindowConfiguration the class has been deleted. The properties of this class are now available on the AppWindow itself, or on the Presenter Classes.
  • More bool the return values ​​for the WinRT API methods in this space have been removed and are now void since these methods would always be successful.
  • C # ImportDll calls are no longer needed for GetWindowIdFromWindow and GetWindowFromWindowId. Use the .NET wrapper methods available in Microsoft.UI.Win32Interop instead of.

Important limits:

  • The Windows Application SDK currently does not provide methods for attaching UI framework content to an AppWindow; you are limited to using the HWND interoperability access methods.
  • Customization of the window title bar works only on Windows 11. Use the IsCustomizationSupported method to verify support for the customization of the title bar feature. We intend to lower this functionality.

For more information, see Manage application windows.

Important limits:

  • This version of AppWindow is currently only available for Win32 applications (both packaged and unpackaged).
  • The Windows Application SDK currently does not provide methods for attaching UI framework content to an AppWindow; you are limited to using the HWND interoperability access methods.
  • Customization of the window title bar works only on Windows 11. Use the IsCustomizationSupported method to verify support for the customization of the title bar feature. We intend to lower this functionality.

For more information, see Manage application windows.

Grab

New Updates:

  • Improved support for precision touchpad input.

Important limits:

  • All static factory functions of PointerPoint have been removed: GetCurrentPoint, GetCurrentPointTransformed, GetIntermediatePoints, and GetIntermediatePointsTransformed.
  • Windows Application SDK does not support recovery Pointer objects with pointer IDs. Instead, you can use the Pointer member function GetTransformedPoint to retrieve a transformed version of an existing one Pointer object. For intermediate points, you can use the PointEventArgs member functions GetIntermediatePoints and GetTransformedIntermediatePoints. See the documentation for more details.

MRT core

New Updates:

  • Application developers can now disable indexing of an image file or RESW file in the PRI file in .NET projects. See number 980 for more information.

Important limits:

  • In .NET projects, copy-pasted resource files in the project folder are not indexed on F5 if the application has already been created. To work around the problem, rebuild the application. See number 1503 for more information].
  • In .NET projects, existing resource files added from an external folder are not indexed without manual setting of the build action. To work around this problem, set the build action in Visual Studio: Content for image files and PRIResource for RESW files. See number 1504 for more information.

Deployment for unpackaged applications

New features:

  • Windows App SDK 1.0 Preview 2 introduces a .NET wrapper for the Bootstrap API. The Bootstrap API is a set of native C / C ++ functions that unpackaged applications should use to dynamically take a dependency on the Windows App SDK framework package at run time. The .NET wrapper provides an easier way to call the Bootstrap API from .NET applications, including Windows Forms and WPF applications. The .NET wrapper for the Bootstrap API is available in the Microsoft.WindowsAppRuntime.Bootstrap.Net.dll assembly, which is local to your application project. For more information about the .NET wrapper, see the .NET wrapper library.
  • Packaged applications can now use the Deploy API to get the main and singleton MSIX packages installed on the machine. The main and singleton packages are part of the framework package that is installed with the app, but due to a limitation with the Windows app model, packaged apps will need to take this extra step in order to install these packages. For more information on how the Deployment API works, see the Packaged Applications Deployment Guide.

Application lifecycle

Most of the app lifecycle features already exist on the UWP platform and have been incorporated into the Windows App SDK for use by all types of apps, especially unpackaged console apps, mobile devices, etc. Win32 applications, Windows Forms applications, and WPF applications. The Windows App SDK implementation of these features cannot be used in UWP apps because there are equivalent features in the UWP platform itself.

Non-UWP apps can also be packaged in MSIX packages. Although these applications can use some of the functionality of the Windows SDK application lifecycle, they should use the manifest approach when it is available. For example, they can’t use the Windows app SDK RegisterForXXXActivation API and must instead register for rich activation through the manifest.

All the constraints for packaged applications also apply to WinUI applications, which are packaged, and there are additional considerations described below.

Learn more and find download links from Microsoft here.


Source link

Share.

About Author

Leave A Reply