Bug 269202

Summary: [compare] Open Declaration does not work in Java compare editor if target is not in visible segment
Product: [Eclipse Project] JDT Reporter: Markus Keller <markus.kell.r>
Component: TextAssignee: Tomasz Zarna <tomasz.zarna>
Status: CLOSED WONTFIX QA Contact:
Severity: normal    
Priority: P3 CC: daniel_megert
Version: 3.5   
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
Whiteboard: stalebug
Bug Depends on: 261199    
Bug Blocks:    
Attachments:
Description Flags
Patch v01
none
mylyn/context/zip none

Description Markus Keller CLA 2009-03-18 10:58:10 EDT
I20090317-1745

- open a Java compare editor with changes in one of the methods
- in the structure compare pane, doubleclick a method to only show changes in that segment
- in the method body, try to open the declaration of a method that is defined in the same class (F3 or Ctrl+Click)
=> caret is moved to start or end of visible segment
=> expected: should remove the selection in the structure compare, show the whole CU, and select the declaration
Comment 1 Dani Megert CLA 2009-03-26 05:22:10 EDT
Tomasz, we call
org.eclipse.compare.internal.CompareEditorSelectionProvider.setSelection(ISelection, boolean)

There we should recognize if the selection is out of scope and then show the full source before setting the selection.
Comment 2 Tomasz Zarna CLA 2009-03-27 06:22:14 EDT
Created attachment 130085 [details]
Patch v01

A possible solution for the issue but given the fact that it uses IPropertyChangeListener facility to reset the selection it's not the best way to do it (see bug 261199).
Comment 3 Tomasz Zarna CLA 2009-03-27 06:22:18 EDT
Created attachment 130086 [details]
mylyn/context/zip
Comment 4 Tomasz Zarna CLA 2009-03-27 06:26:38 EDT
We need to either fix bug 261199 or figure out something completely different but still not involving the IPropertyChangeListener facility.
Comment 5 Tomasz Zarna CLA 2009-03-27 06:27:51 EDT
You should also keep in mind Dani's work made on bug 165434.
Comment 6 Eclipse Genie CLA 2020-01-15 19:50:19 EST
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.