Skip to content

debugui: Incorrect InputCapturingState when panel is collapsed #34

Closed
@mikenye

Description

@mikenye

I've noticed that the InputCapturingState of the panels returns an incorrect value when the panel is collapsed.

For example:

With mouse hovering over expanded panel, the state is correctly identified as InputCapturingStateHover (mouse cursor not shown, but is next to "Hi-Res" in "Demo Window"):

Image

With "Demo Window" collapsed, but the mouse cursor where the Demo Window would have been:

Image

The issue seems to be with the bounds calculation here:

if pt.In(cnt.layout.Bounds) {

A fix would be to subtract cnt.layout.BodyBounds.Dy() from cnt.layout.Bounds.Max.Y.

I will submit a PR shortly.

Thanks.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions