[cp-patches] FYI: LightweightDispatcher fix/optimization

Roman Kennke kennke at aicas.com
Thu Jun 8 16:12:28 UTC 2006


This gets rid of AWTUtilities.convertPoint() calls in
LightweightDispatcher. This is much more efficient (avoids allocations
of Point objects AND avoids double conversion to screen coordinates and
back, which is error prone anyway). It also fixes a problem that Lillian
had with one applet.

2006-06-08  Roman Kennke  <kennke at aicas.com>

        * java/awt/LightweightDispatcher.java
        (handleMouseEvent): Replaced calls to
AWTUtilities.convertPoint()
        with convertPointToChild(). This is more efficient and avoids
        problems with getLocationOnScreen().
        (findTarget): Check for component beeing showing() early.
        Simplified AWTUtilities.convertPoint() to a simple substraction
        operation.
        (convertPointToChild): New helper method.

/Roman

-------------- next part --------------
A non-text attachment was scrubbed...
Name: patch.diff
Type: text/x-patch
Size: 7689 bytes
Desc: not available
Url : http://developer.classpath.org/pipermail/classpath-patches/attachments/20060608/2df73c33/patch.bin


More information about the Classpath-patches mailing list