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

Alternative active window ID/handle #333

Closed
RedSkittleFox opened this issue Sep 16, 2024 · 5 comments
Closed

Alternative active window ID/handle #333

RedSkittleFox opened this issue Sep 16, 2024 · 5 comments

Comments

@RedSkittleFox
Copy link
Contributor

RedSkittleFox commented Sep 16, 2024

The function IsHoveringWindow would always return false, partially because I was using imguizmo inside another window that had IO for camera controls. I propose the change to add an alternative window handle / id that the IsHoveringWindow function would accept as valid.

I propose adding a following variable and check to the IsHoveringWidnow to allow users to embed imguizmos inside their own windows.

https://github.com/RedSkittleFox/ImGuizmo/blob/ce1092a924505eb561ce35132fcf9096137a35bf/ImGuizmo.h#L221

https://github.com/RedSkittleFox/ImGuizmo/blob/ce1092a924505eb561ce35132fcf9096137a35bf/ImGuizmo.cpp#L927C16-L941C1

@maritim
Copy link
Contributor

maritim commented Sep 20, 2024

Hello @RedSkittleFox!

I've identified the problem as well and mentioned it in issue #327. I've provided more details there regarding this situation you presented, and I proposed a similar approach.

From what I can tell, using the ImGuizmo library with ImGui's docking branch has some problems and incompatibilities. The situation is that the owner of this library has never been particularly interested in ensuring compatibility with this branch, even though it has recently become very widely used. Additionally, as I understand it, the plan for ImGui is to adopt the docking branch directly into the master.

@CedricGuillemet , could you take a look at this situation, please? Thank you!

@CedricGuillemet
Copy link
Owner

yes, it's been a while since the last update. I'll take care of that this weekend.

@CedricGuillemet
Copy link
Owner

@RedSkittleFox Can you please do a PR? Can this feature be tested in the testApp with 2 windows, without the docking branch?

@RedSkittleFox
Copy link
Contributor Author

RedSkittleFox commented Sep 24, 2024

Yes, here is the PR. I have not tested it with 2 windows. I can do it later today (in about 10 hours).
#335

@CedricGuillemet
Copy link
Owner

Should be fixed now. Closing.

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

No branches or pull requests

3 participants