Eclipse Community Forums - RDF feed
https://www.eclipse.org/forums/
Eclipse Community Forumsselection in ecore editor reverting to previous node
https://www.eclipse.org/forums/index.php/mv/msg/196699/627094/#msg_627094
1. Modify a field in your property sheet.
2. Without changing focus from the property sheet field, select a new node in the ecore editor.
What I'd expect to happen is something similar to what happens when you select a new field in the property sheet, which is the original field completes the assignment, and the selection stays on the new cell.
What happens if you select a field in the editor (moving from the property sheet) is that the original field in the property sheet completes its assignment, but the selection in the editor page jumps back to the original node.
]]>Jay Norwood2010-09-22T20:56:27-00:00Re: selection in ecore editor reverting to previous node
https://www.eclipse.org/forums/index.php/mv/msg/196699/627884/#msg_627884
Invoking a command generally updates the selection to be the object
affected by the command. E.g., when you create a child, the child is
selected. So while what you describe might be a little annoying, it is
expected. If you complete the cell editing (e.g., with an enter) before
you select, you'll get different behavior.
Jay Norwood wrote:
> I've noticed a selection issue that involves interaction between
> property sheet and the emf generated editor, which can be
> demonstrated in the ecore editor.
>
> 1. Modify a field in your property sheet.
> 2. Without changing focus from the property sheet field, select a new
> node in the ecore editor.
>
>
> What I'd expect to happen is something similar to what happens when
> you select a new field in the property sheet, which is the original
> field completes the assignment, and the selection stays on the new cell.
>
> What happens if you select a field in the editor (moving from the
> property sheet) is that the original field in the property sheet
> completes its assignment, but the selection in the editor page jumps
> back to the original node.
>
>]]>Ed Merks2010-09-23T06:23:54-00:00Re: selection in ecore editor reverting to previous node
https://www.eclipse.org/forums/index.php/mv/msg/196699/628689/#msg_628689
I encountered another instance where this causes problems while using the editor. I had copied an instance of a class and wanted to paste it multiple times in the editor, but with each paste the selection was moved to the pasted object, making it necessary for me to scroll back to the original tree node and select it again for each paste.
I think in general it would be a good idea to let the user decide when to change the selection. Is there some use case that requires the pasted object to be selected?
Jay]]>Jay Norwood2010-09-23T17:07:22-00:00Re: selection in ecore editor reverting to previous node
https://www.eclipse.org/forums/index.php/mv/msg/196699/628704/#msg_628704
I think your first problem is that Properties is a View not an Editor
and Views do not have selections. e4 changes this.
I think the second behaviour is correct, it is generally more annoying
to be left with the selection on the old object which you then edit
inadvertently. The behaviour is irritating, but I think that is because
of the difficulty of selecting e.g. an EPackage as the paste target when
100 EClass children are displayed. Perhaps a cursor-up/page-up
navigation would solve this.
Regards
Ed Willink
On 23/09/2010 18:07, Jay Norwood wrote:
> I think it is counter to general guidelines to go against the user's
> selection choice.
> I encountered another instance where this causes problems while using
> the editor. I had copied an instance of a class and wanted to paste it
> multiple times in the editor, but with each paste the selection was
> moved to the pasted object, making it necessary for me to scroll back to
> the original tree node and select it again for each paste.
> I think in general it would be a good idea to let the user decide when
> to change the selection. Is there some use case that requires the pasted
> object to be selected?
> Jay]]>Ed Willink2010-09-23T17:29:58-00:00Re: selection in ecore editor reverting to previous node
https://www.eclipse.org/forums/index.php/mv/msg/196699/628773/#msg_628773
Have you considered what issues this behavior might cause with gui test code? I've written a number of test cases with swtbot, and it is very tedious to have to work around such cases where a program decides to select something other than what you have specified. ]]>Jay Norwood2010-09-24T05:36:39-00:00