Open sylveon opened 5 years ago
@sylveon , I took the liberty of making a trimmed down example that demonstrates the basics required for setting up Xaml Islands with Win32 and C++. Feel free to let me know how you get on with it. https://github.com/MarkIngramUK/XamlIslands
The example tries to show me how to wrap window behavior in a class, which I already know how to and I already did in my code base: I'm trying to integrate Xaml Islands to an existing application, not trying to undo your abstractions so that I can understand what is going on (it hides important behavior in base classes split around the whole code base - the main part of getting Xaml Islands working, creating a DesktopWindowXamlSource, isn't even in the file with the entry point)
It doesn't explain design decisions: why use an event revoker for an event which literally just changes a text label's content???
Thought you could run it to understand it better? Too bad for you (after you've figured out how to make a self-signed certificate, of course, because none is included in the repo and VS isn't smart enough to generate a new one on its own, instead redirecting you to some PowerShell commands with arcane parameters): (trying to launch the SampleCppApp directly instead project gives you a module not found hresult exception)
The examples should be kept to minimal changes from the base vs project for a win32 desktop app, and have the whole code in 1 or 2 files. Custom controls in such an example would be fine, because it's ignorable when trying to get the base stuff running.