|
Quick Lists
|
|
Bug ID:
|
6184866
|
|
Votes
|
1
|
|
Synopsis
|
BasicTreeUI should use factory method to construct drop target listener
|
|
Category
|
java:classes_swing
|
|
Reported Against
|
|
|
Release Fixed
|
|
|
State
|
11-Closed, duplicate of 4468566,
request for enhancement
|
|
Priority:
|
4-Low
|
|
Related Bugs
|
4942851
|
|
Submit Date
|
26-OCT-2004
|
|
Description
|
A DESCRIPTION OF THE REQUEST :
The BasicTreeUI installListeners() method directly instantiates a TreeDropTargetListener to respond to DropTarget events. The rest of the installListeners() method use factory methods to add a level of indirection in creating these listener classes.
JUSTIFICATION :
A factory method should be used for TreeDropTargetListener too to allow custom L&Fs to provide custom TreeDropTargetListener.
The pattern of using factory methods should be part of the L&F coding standards.
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
I'd like to see a createDropTargetListener() method in BasicTreeUI with installListeners() calling it.
CUSTOMER SUBMITTED WORKAROUND :
The workaround is to copy the BasicTreeUI installListeners() method to BasicTreeUI subclass and change the creation of TreeDropTargetListener to desired class.
xxxxx@xxxxx 10/26/04 22:30 GMT
|
|
Work Around
|
N/A
|
|
Evaluation
|
The fixes for 4468566 and 4942851 will re-architect Swing's drop support to make it much more usable by the developer. In particular, they will provide location sensitive dropping, and much better indication of the drop location. As a result of this re-architecture, BasicTreeUI will no longer install a drop target listener, as all the details of indicating drop locations will be handled within TransferHandler. Closing as a duplicate.
xxxxx@xxxxx 2005-05-20 15:19:25 GMT
|
|
Comments
|
PLEASE NOTE: JDK6 is formerly known as Project Mustang
|
|
|
 |