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

Performance: Swing drop locations should override equals

    XMLWordPrintable

Details

    Description

      JList, JTable, JTree, JTextComponent fire a property change to indicate when there is a change to the drop location. Right now, these notifications are sent out repeatedly during DnD, even if the mouse isn't moved and the real location hasn't changed. This can be expensive if each change triggers a repaint or some other action.

      PropertyChangeSupport is designed to only send notifications if the value is actually changed, but to take advantage of this, DropLocations need to override equals().

      And to be correct, they should also override hashCode().

      Attachments

        Activity

          People

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

            Dates

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: