Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-6424148

Off-by-one error causes AssertionFailure with JTree drag and drop

XMLWordPrintable

    • b92
    • generic
    • generic

      Compile and run the attached "TreeDnDDemo.java" with system assertions enabled:
      java -esa TreeDnDDemo

      Drag from the component labelled "Drag from here" over the tree. When dragging over leaf nodes slowly, you'll see assertion failures.

      This is caused by off by one errors in the drop location calculation. All of JTree/JList/JTable should be checked for these errors.

            shickeysunw Shannon Hickey (Inactive)
            shickeysunw Shannon Hickey (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: