microsoft / WindowsAppSDK-Samples

Feature samples for the Windows App SDK
MIT License
685 stars 217 forks source link

cpp-win32-unpackaged #319

Closed worldhe closed 4 months ago

worldhe commented 8 months ago

https://github.com/microsoft/WindowsAppSDK-Samples/tree/main/Samples/Islands/cpp-win32-unpackaged Hello, I have 3 questions to ask about the above link. 1.Is "WinAppSDK island" in README referring to WindowsAppSDK island 2.Is "WinAppSDK island" in README referring to XAML Islands(https://learn.microsoft.com/zh-cn/windows/apps/get-started/windows-developer-glossary#xaml-islands) 3.Why is C++/WinRT's XAML used instead of WinUI3 if WindowsAppSDK is being used

JesseCol commented 4 months ago

Hi, sorry for the confusion here.

1.Is "WinAppSDK island" in README referring to WindowsAppSDK island 2.Is "WinAppSDK island" in README referring to XAML Islands(https://learn.microsoft.com/zh-cn/windows/apps/get-started/windows-developer-glossary#xaml-islands)

Firstly, "WinAppSDK" and "WindowsAppSDK" refer to the same thing, in case that wasn't clear.

"WinAppSDK island" is a term we've used in a few places to distinguish Xaml Islands in WinAppSDK/WinUI3 from Xaml Islands using Windows "system" Xaml / WinUI2. "WinAppSDK Island" here specifically refers to the Microsoft.UI.Xaml.Hosting.DesktopWindowXamlSource class. The link you mentioned above is about "system" Xaml, which contains the Windows.UI.Xaml.Hosting.DesktopWindowXamlSource API.

3.Why is C++/WinRT's XAML used instead of WinUI3 if WindowsAppSDK is being used

C++/WinRT is a technology that helps C++ apps to consume WinRT APIs. You can use it to interact with many WinRT APIs, including WinAppSDK APIs. The sample uses C++/WinRT and WindowsAppSDK, which contains WinUI3.

Thanks!