Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 329798 - [General] Cannot define different editors for the same EObject using an additional filter
Summary: [General] Cannot define different editors for the same EObject using an addit...
Status: NEW
Alias: None
Product: Papyrus
Classification: Modeling
Component: Core (show other bugs)
Version: 1.0.0   Edit
Hardware: All All
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-11-09 09:49 EST by Yann Tanguy CLA
Modified: 2017-09-08 09:49 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Yann Tanguy CLA 2010-11-09 09:49:58 EST
Currently it does not seem to be possible to have distinct editors for the same element with a filtering condition :
e.g the selected EObject is a Property and I want to register 
- A UML editor for Property
- A SysML editor if the Property is Stereotyped ConstraintProperty
- A SysML editor if the Property is a Part
- ...

Let me know if I missed something offering such capability.

Also, is it possible to register Diagram specific editor (relying on the kind of selected GraphicalEditPart rather than the semantic element) ?
Comment 1 Remi Schnekenburger CLA 2010-11-10 05:17:42 EST
(In reply to comment #0)
> Currently it does not seem to be possible to have distinct editors for the same
> element with a filtering condition :
> e.g the selected EObject is a Property and I want to register 
> - A UML editor for Property
> - A SysML editor if the Property is Stereotyped ConstraintProperty
> - A SysML editor if the Property is a Part
> - ...
> 
> Let me know if I missed something offering such capability.
> 
> Also, is it possible to register Diagram specific editor (relying on the kind
> of selected GraphicalEditPart rather than the semantic element) ?

No, you missed nothing, it is only possible to register a property editor given the type of element, it does not provide an advanced filter.

For the selected edit part: I would prefer not to rely only on the kind of Edit part selected, as the editor should be able to work on property views or model explorer. Also, the extension point should stay independant of the GMF framework.

=> A way to define specific filters should be implemented in the embedded editor framework. Perhaps something inspired from the filters of the property views could be implemented.