-
Notifications
You must be signed in to change notification settings - Fork 59
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: Re-think WindowManager API #772
Comments
you shouldn't be able to set the display mode dynamically on a window, should be done at creation time. Also on android, WebGPU, etc. you won't be able to create or destroy a window, that stuff belongs in the specific Win32, Wayland, etc. window managers Why is Btw the reason why cursor control is a separate thing is because the Cursor may be HW and separate from all windowing stuff, but also a per-window thing (Android and Web). |
right, a bunch of these can't be implemented in android anyways, that's why we can return
typo. edited.
got it. edited. |
I'll let @Erfan-Ahmadi deal wtih this, just remember that windows need to keep the window manager alive. And on Win32 and other fun legacy platforms, every window method needs to defer/pump its action onto a dedicated thread & queue that belongs to the window manager (implementation detail I guess). @alichraghi so that we don't "fuck it up" I'd be willing to sponsor a Linux/Wayland implementation out of our R&D budget. |
Motivation
Currently the windowing API is split into
IWindowManager
,IWindow
andICursorControl
. the choosen names here mostly makes sense as all(?) windowing APIs offers similar functionality where you can query monitors and other stuff like creating the window and then the part where you manage window specific features.however Nabla's api is kind of weird in this sense. you can create a window from
IWindowManager
and yet it's per window!? why is some methods insideIWindowManager
and some inIWindow
. we've also got a bunch of conflicting flags, etc.let alone the existence ofICursorControl
..Proposal
Considering that we need multi-windowing and the ability to query monitors (to create windows from), here is how i see the final API:
(NOTE: i was lazy to write getters ^)
The text was updated successfully, but these errors were encountered: