Menu

#6 Mousing out quickly leaves last highlighted leaf highlighted

v1.0 (example)
open-fixed
5
2011-09-30
2007-01-24
No

When the JTreeMap is embeded in another component (such as the split pane in your example code) mousing out quickly causes the last leaf node that was highlighted (via mouseover) to remain highlighted. From my testing it appears that this occurs because the mouse moves too quickly over the very small border of the JTreeMap to register as no longer pointing at any leaf, so the active leafnode is never set to null. The fix was simply adding a protected inner class that extends MouseAdapter and overwrites MouseExited to set the active leaf to null and repaint on mouse exit.

Discussion

  • Allen Harvey

    Allen Harvey - 2007-01-24

    a patch for JTreeMap, to show the necessary changes to resolve the issue

     
  • Allen Harvey

    Allen Harvey - 2007-01-24
    • summary: Mousing Out Quickly leaves last highlighted leaf highlighted --> Mousing out quickly leaves last highlighted leaf highlighted
     
  • Nobody/Anonymous

    Logged In: NO

    I tried this work around. It doeas not work. In the reveal() method of tree map the color is set to transparency color and a rectangle is filled. Calling repaint, setting background color - nothing seems to work. Could a correct work around be given, very urgent please .

     
  • Allen Harvey

    Allen Harvey - 2007-07-09

    A patched version of JTreeMap.java, from version 1.1

     
  • Allen Harvey

    Allen Harvey - 2007-07-09

    Logged In: YES
    user_id=1700602
    Originator: YES

    I just re-tested the patch on the new version of JTreeMap that was released (1.1). The problem still persists and the patch still fixes it. If you are having problems patching the main file, download the patched version of JTreeMap.java that is attached to this post.
    File Added: JTreeMap.java

     
  • Nobody/Anonymous

    Logged In: NO

    Thank you.The patch worked. A small mistake on my side.

     
  • Nobody/Anonymous

    Logged In: NO

    Thank you.The patch worked. A small mistake on my side.

     
  • Laurent Dutheil

    Laurent Dutheil - 2011-09-30
    • assigned_to: nobody --> jense128
     
  • Laurent Dutheil

    Laurent Dutheil - 2011-09-30
    • status: open --> open-fixed
     
  • Laurent Dutheil

    Laurent Dutheil - 2011-09-30

    fixed in 1.1.1

     

Log in to post a comment.

MongoDB Logo MongoDB