Skip to main content



      Home
Home » Modeling » EMF » selection in ecore editor reverting to previous node
selection in ecore editor reverting to previous node [message #627094] Wed, 22 September 2010 16:56 Go to next message
Eclipse UserFriend
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.


Re: selection in ecore editor reverting to previous node [message #627884 is a reply to message #627094] Thu, 23 September 2010 02:23 Go to previous messageGo to next message
Eclipse UserFriend
Jay,

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.
>
>
Re: selection in ecore editor reverting to previous node [message #628689 is a reply to message #627884] Thu, 23 September 2010 13:07 Go to previous messageGo to next message
Eclipse UserFriend
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
Re: selection in ecore editor reverting to previous node [message #628704 is a reply to message #628689] Thu, 23 September 2010 13:29 Go to previous messageGo to next message
Eclipse UserFriend
Hi Jay

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
Re: selection in ecore editor reverting to previous node [message #628773 is a reply to message #628704] Fri, 24 September 2010 01:36 Go to previous message
Eclipse UserFriend
I recall there are gui development guidelines which say you shouldn't do things like this. Selection is something the user owns.

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.
Previous Topic:how to solve ecore lib issue
Next Topic:Using EMF generated objects with easyb and Groovy
Goto Forum:
  


Current Time: Tue Jul 01 15:17:32 EDT 2025

Powered by FUDForum. Page generated in 0.03313 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top