DefaultWindow by default would not have MousePassThroughEnabled set to True, but to False

Issue #849 resolved
Lukas Meindl created an issue

While with other windows it is understandable and intuitive that they do not have mouse inputs passing through, the default window in contrast, in case it has no LNF attached and would not render anything, should not have such behaviour in my opinion. If plainly created as "DefaultWindow", there should be an exception made for this window, making it have per default have the pass through set to true.

I am not sure this can be done in a nice way, or will rather make CrazyEddie vomit while reading. Either way i wanted to bring it up because it has "surprised" me a couple of times.

Reproducibility: always

Comments (2)

  1. Lukas Meindl reporter

    On second thought this might confuse people that rely on having the default window accepting clicks and mouse movement, thus forget my initial suggestion.

    The question however is: why does MouseInputPropagationEnabled not resolve the following issue: (underlines for spacing)

    DefaultWindow1

    ___

    DW2_FrameWindow1

    FW2

    FW=FrameWindow DW = DefaultWindow DefaultWindow1 and 2 cover full screen, the framewindows are not big DefaultWindow2 is set to MouseInputPropagationEnabled = True Clicking FW2 puts DW2 in front of FW1. Thus "visually" clicking FW1 hits DW2-. But the unhandled input still will not be passed on back to DW1 and then on to FW1 for some reason.

    I thought MouseInputPropagationEnabled would do this?

  2. Paul Turner

    With propagation enabled, Events do not bounce backwards and forwards in the window hierarchy like a ping pong ball until some window is found that handles the event.

    As the documentation for the mouse input propagation states: <em>Set whether mouse input that is not directly handled by this Window (including its event subscribers) should be propagated back to the Window's parent.</em> The event is simply passed back to the parent window until either the root window is found or until a window that does not propagate is reached. At this point the event is considered to have been dealt with and the appropriate return value is returned from the inject* function.

    BTW the original suggestion would also be rejected.

    The solution is to make nicely structured layouts - not hack code because the layouts suck.

  3. Log in to comment