<AWT Dev> Review request: 6689983 (reevaluate our inset-related code in XAWT)

Oleg Sukhodolsky son.two at gmail.com
Wed Jun 24 06:22:23 PDT 2009

On Wed, Jun 24, 2009 at 5:09 PM, Anthony Petrov<Anthony.Petrov at sun.com> wrote:
> On 06/23/2009 11:26 PM, Oleg Sukhodolsky wrote:
>>>> src/solaris/classes/sun/awt/X11/XWindow.java
>>>> why we need SubstructureNotifyMask?  I see that because of it event
>>>> processing becomes a little bit more
>>>> error prone, so it would be better to understand why we need this.
>>> Well, as the comment above the XWindow.handleReparentNotifyEvent()
>>> states,
>>> this is needed to guarantee receiving the ReparentNotify events just
>>> after
>>> mapping the window. Currently commenting out the SubstructureNotifyMask
>>> seems to not make things generally worse, and I don't actually remember
>>> how
>>> exactly I reproduced the issue.
>>> Guess I need to remove it because theoretically it should all work w/o
>>> this
>>> event mask. I'm just a bit scared to re-run all the tests after that
>>> change
>>> though...
>> I understand you pain, but ... we need to be sure that we need (or do
>> not need) this mask.
> So I rerun the majority of automatic top-level windows-related tests, they
> seem to work w/o problems. I'll remove the mask in the XWindow, however I
> will leave unchanged the checks for the window ID in the event handlers
> since the SubstructureNotifyMask may be set in other places - notably, even
> the XBaseWindow sets it under some circumstances. In any case, they do not
> harm.

It is a good news that we do not need the mask.  Although I'm not a
big fun of unneeded code,
I believe it is up to you to either keep it or remove.

> --
> best regards,
> Anthony

More information about the awt-dev mailing list