I located the change the created the problem - I'll see about providing a fix, but it might be slightly complex. I'll let you know when a test version of muimaster.library is available.
I'm having problem providing a logical, good fix for that. Does anyone know active developers forums, especially for OS programming (so not low level assember/demos/games)? I tried posting my questions on EAB but didn't get any answer.
I'll repost my question here as well:
I'm currently looking into an incompatibility with HandleEvent implementaiton in AROS and looking for some help understanding a specific situation. Please note that I'm limiting the scope to handling IDCMP_MOUSEBUTTONS only.
What believe is happening under MUI 3.8 is:
a) Area object is not "eating" a IDCMP_MOUSEBUTTONS event. An event handler registered at priority -20 still received IDCMP_MOUSEBUTTONS event regardless on coordinates of click - even if valid button was clicked.
b) An object that is hidden (MUIA_ShowMe, FALSE) will still receive events via HandleEvent as long as it's event node is not removed via MUIM_Window_RemEventHandler.
Using a button usecase (MUIC_Text), my question is how does and object know that it should handle that click.
In the MUI examples and in open source custom classes I see this kind of code in MUIM_HandleEvent
Code:
if (_isinobject(msg->imsg->MouseX,msg->imsg->MouseY))
Which essentially says: if the coordinates are within my bounds, I should handle the click. This works in the following situation:
Have a horizontal group with two button. Click on left one - the click is not within bounds of right button, so it does not react. Click on the right one, the left one does not react. However, now hide (MUIA_ShowMe, FALSE) right button. What happens is that left button is extended to covert the empty space. Now clicking on where where right button was, because of a) and b) above causes the hidden right button to still receive the event. The right button, although not visible, still retain bounds which make the check above pass. So the hidden right button should react to the click, but obviously it does not.
Does anyone who why the hidden button is not reacting to a click?
The ideas that came to my mind are:
1) The checks in MUI classes check not only coordinates of the click, but also if object is not hidden. However why the would all the examples of custom classes check only coordinates of click?
2) MUI classes remove event handler node as reaction to MUIM_ShowMe, FALSE. However example show manipulation of event handler nodes only in MUIM_Setup/MUIM_Cleanup. Example which have event handler node are not handling MUIM_ShowMe