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

Bug 322427

Summary: Duplicate messages appear in annotation and source hovers
Product: z_Archived Reporter: Adam Taylor <awtaylor>
Component: IMPAssignee: Robert M. Fuhrer <rfuhrer>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3    
Version: unspecified   
Target Milestone: ---   
Hardware: All   
OS: All   
Whiteboard:
Attachments:
Description Flags
a possible implementation
none
junit test for patch none

Description Adam Taylor CLA 2010-08-11 16:01:30 EDT
Build Identifier: 

The IMP provided annotation and source hovers will show duplicate error messages when a given source offset has both an Annotation and a MarkerAnnotaion (which are both produced in the default implementation).

If there are multiple Annotations on a given line (at the same offset) only one of them should be displayed in hovers.

Reproducible: Always
Comment 1 Adam Taylor CLA 2010-08-11 16:08:20 EDT
Created attachment 176394 [details]
a possible implementation

This fixes the above scenario, and also contains the following refactorings:

static functionality of AnnotationHoverBase moved into AnnotationUtils
all references to AnnotationHoverBase changed to AnnotationUtils
AnnotationHoverBase removed
Comment 2 Adam Taylor CLA 2010-08-11 17:07:00 EDT
Created attachment 176410 [details]
junit test for patch
Comment 3 Robert M. Fuhrer CLA 2010-08-12 16:59:26 EDT
Quick sanity check on the patches: you wrote them all and/or borrowed code from elsewhere in the Eclipse SDK, right?
Comment 4 Adam Taylor CLA 2010-08-13 10:38:21 EDT
That's correct.  I wrote one function and the rest was a refactor of existing IMP code.
Comment 5 Robert M. Fuhrer CLA 2010-09-09 13:27:40 EDT
Patch reviewed and applied to HEAD of SVN trunk.

Thanks, Adam!!