Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 320199

Summary: [preferences] UserLibraryPreferencePage Edit/Remove do not work as expected when same jar is contained in 2 or more libs
Product: [Eclipse Project] JDT Reporter: Raksha Vasisht <raksha.vasisht>
Component: UIAssignee: Raksha Vasisht <raksha.vasisht>
Status: VERIFIED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: daniel_megert, deepakazad, markus.kell.r
Version: 3.7   
Target Milestone: 3.7 M1   
Hardware: PC   
OS: Windows XP   
Whiteboard:
Attachments:
Description Flags
Patch daniel_megert: review+

Description Raksha Vasisht CLA 2010-07-18 15:09:17 EDT
Created attachment 174583 [details]
Patch

I20100713-0800

Steps :

1) Go to UserLibraryPreferencePage, add a new lib and a jar under it (A -> x.jar)
2) Add another lib and same jar (B -> x.jar)
3) Edit one of the attributes in the second jar B -> x.jar
=> The value shows up in A-> x.jar . Same problem with Remove as well.



Attaching a patch.
We should refresh the parent container always since that uniquely identifies the list elements and the attributes and refreshes the appropriate element and not the first occurrence of the element in the tree.
Comment 1 Dani Megert CLA 2010-07-19 10:40:57 EDT
Patch looks good!
Comment 2 Raksha Vasisht CLA 2010-07-21 02:32:29 EDT
Committed to HEAD.
Comment 3 Deepak Azad CLA 2010-08-03 14:14:41 EDT
Verified with I20100802-1800 on Ubuntu.