This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 72381 - Disable Remove button for Required Tokens appropriately
Summary: Disable Remove button for Required Tokens appropriately
Status: RESOLVED FIXED
Alias: None
Product: apisupport
Classification: Unclassified
Component: Project (show other bugs)
Version: 5.x
Hardware: All All
: P4 blocker (vote)
Assignee: Martin Krauskopf
URL:
Keywords: SIMPLEFIX
Depends on:
Blocks:
 
Reported: 2006-02-08 05:53 UTC by Martin Krauskopf
Modified: 2006-02-27 16:22 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Krauskopf 2006-02-08 05:53:14 UTC
Until there is at least one selection.
Comment 1 Martin Krauskopf 2006-02-27 11:19:31 UTC
..and also automatically select just added one

ui/customizer/CustomizerLibraries.java; 1.46 -> 1.47;
Comment 2 Martin Krauskopf 2006-02-27 13:01:05 UTC
Really do not know why (probably lack of my UI knowledge), but sometime
JList.getMinSelectionIndex() (delegate to selection model) returns value >
JList.getModel().getSize() which causes AIOOBE in our custom model. I'll have to
add sanity check into getElementAt into our model. If anybody know what's going
on, let me know.
Comment 3 Martin Krauskopf 2006-02-27 13:14:56 UTC
So should be ok now.

ui/customizer/CustomizerComponentFactory.java; 1.10 -> 1.11;
ui/customizer/CustomizerLibraries.java; 1.47 -> 1.48;
Comment 4 Martin Krauskopf 2006-02-27 13:45:30 UTC
Backported.

ui/customizer/CustomizerComponentFactory.java; 1.9.2.1 -> 1.9.2.2;
ui/customizer/CustomizerLibraries.java; 1.44.2.2 -> 1.44.2.3;
Comment 5 Jesse Glick 2006-02-27 16:10:21 UTC
Re. JList behavior - sounds like a Swing bug to me, so if you can reproduce in a
standalone case that would be a good bug report I think?
Comment 6 Martin Krauskopf 2006-02-27 16:22:51 UTC
I'll put it on my todo list. Do not believe too much to JDK bug, though did not
find anything strange in our implementation. Seems to me like some data are
shared between two selection models inappropriately since one instance of
selection model returns actually its minSelectionIndex equals to selection index
of other one. Or maybe selection model itself is somehow reused. Also those two
lists models has the same elements shared (Strings). Hmm, litle confused. I'll
have to investigate more.