Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Proposal for future windowing mechanisms for Win32 apps #166

Open
AzAgarampur opened this issue Sep 2, 2020 · 1 comment
Open

Proposal for future windowing mechanisms for Win32 apps #166

AzAgarampur opened this issue Sep 2, 2020 · 1 comment
Assignees

Comments

@AzAgarampur
Copy link

AzAgarampur commented Sep 2, 2020

Proposal: Win32 apps can use WinRT to create modern window frames.

Summary

UWP apps are launched with a window created for them by ApplicationFrameHost.exe. These are customized Win32 windows, of course. Win32 apps can use WinRT to customize a specific window via an HWND. Internally, it would probably take the window handle and take over window frame composition and create an application frame window that allows a Win32 app to host standard content inside of it.

Rationale

API proposal

I was thinking we could update Windows/Microsoft.UI.Xaml.Window and add a function like AttachToWindow to allow the backend to take control of painting the window we give it via an HWND. We can then call DetatchFromWindow and pass in the previous HWND to stop compositing the modern window and allow the app to take back control customizing its window via the app's own WindowProc.

@Poopooracoocoo
Copy link

#157

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants