Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 319305 - Editor and outline view not linked, even if link editor action is checked
Summary: Editor and outline view not linked, even if link editor action is checked
Status: CLOSED FIXED
Alias: None
Product: TMF
Classification: Modeling
Component: Xtext (show other bugs)
Version: 1.0.0   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: SR1   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 323065
  Show dependency tree
 
Reported: 2010-07-08 14:49 EDT by Samantha Chan CLA
Modified: 2017-09-19 15:54 EDT (History)
2 users (show)

See Also:
sebastian.zarnekow: helios+


Attachments
proposed patch (4.49 KB, patch)
2010-08-05 17:03 EDT, Michael Clay CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Samantha Chan CLA 2010-07-08 14:49:54 EDT
1) Open a file using the XText editor.
2) In this outline view, toggle the link editor action to checked
3) Open another file using the Xtext editor
4) You will notice that the "Link editor" action is checked, which is as expected
6) Uncheck the "Link Editor" action in the second editor -> editor is not linked -> good
7) Go back to the first editor 

->  Notice that the "Link Editor" action is checked -> which is not expected as the preference is stored in a static value in LinkingHelper

->  Keep the action as checked, and select something in the editor -> Nothing in the outline view is selected.  This is because the editor check state and the LinkingHelper static value have gone into inconsistent state.  

I think there needs to be some "listener" implementation in the LinkingHelper and ask the actions to react to changes to the linking property.  Otherwise, we will easily get into inconsistent state.
Comment 1 Samantha Chan CLA 2010-07-08 14:54:15 EDT
After looking deeper, I think the action needs to listen for preference changes from the preference store, for it to be in sync with the preference.
Comment 2 Michael Clay CLA 2010-08-05 17:03:10 EDT
Fixed in HEAD
Comment 3 Michael Clay CLA 2010-08-05 17:03:46 EDT
Created attachment 175982 [details]
proposed patch
Comment 4 Karsten Thoms CLA 2017-09-19 15:54:20 EDT
Closing bug which were set to RESOLVED before Eclipse Neon.0.