Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF » Register EdingDomain as an extenion
Register EdingDomain as an extenion [message #416988] Thu, 21 February 2008 22:23 Go to next message
Charles H Martin is currently offline Charles H MartinFriend
Messages: 79
Registered: July 2009
Member
Is it possible to register a plain-old EditingDomain as an extension point, in the same this can be done with a TransactionalEditingFactory?


Thanks

Charles
Re: Register EdingDomain as an extenion [message #416991 is a reply to message #416988] Thu, 21 February 2008 22:43 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33140
Registered: July 2009
Senior Member
Charles,

No. I'm not sure what this would imply. Maybe Christian will
understand the question better...


Charles Martin wrote:
> Is it possible to register a plain-old EditingDomain as an extension point, in the same this can be done with a TransactionalEditingFactory?
>
>
> Thanks
>
> Charles
>


Ed Merks
Professional Support: https://www.macromodeling.com/
Re: Register EdingDomain as an extenion [message #416992 is a reply to message #416991] Thu, 21 February 2008 23:15 Go to previous messageGo to next message
Charles H Martin is currently offline Charles H MartinFriend
Messages: 79
Registered: July 2009
Member
Thanks, I'll see if I can track him down

You might be able to help anyway, although this is probably more of a platform issue. I am trying to have my views and actions get access to my editing domain, but when I expand the view to full size, I lose the editor (which is where the IEditingDomainProvider is implemented)

Really I want my editingDomain available to the entire application at any time, so I am trying to find a way to achieve this

At first I tried:

private MjtEditor getEditor() {
IWorkbenchWindow workbenchWindow = workbench.getActiveWorkbenchWindow();
IWorkbenchPage page = workbenchWindow.getActivePage();
MjtEditor mjtEditor = (MjtEditor) page.getActiveEditor();

if (mjtEditor == null)
mjtEditor = (MjtEditor) MjtEditorAdvisor.findEditorPart(
workbench, getModelURI());

page.activate(mjtEditor);

return mjtEditor;
}

but then the editor dissapears, the editor here becomes null

Ideas?
Re: Register EdingDomain as an extenion [message #416998 is a reply to message #416992] Fri, 22 February 2008 13:51 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33140
Registered: July 2009
Senior Member
Charles,

Maybe the views and actions can get their editing domain from the
input/selection passed to them? You'd use
AdapterFactoryEditingDomain.getEditingDomainFor...


Charles Martin wrote:
> Thanks, I'll see if I can track him down
>
> You might be able to help anyway, although this is probably more of a platform issue. I am trying to have my views and actions get access to my editing domain, but when I expand the view to full size, I lose the editor (which is where the IEditingDomainProvider is implemented)
>
> Really I want my editingDomain available to the entire application at any time, so I am trying to find a way to achieve this
>
> At first I tried:
>
> private MjtEditor getEditor() {
> IWorkbenchWindow workbenchWindow = workbench.getActiveWorkbenchWindow();
> IWorkbenchPage page = workbenchWindow.getActivePage();
> MjtEditor mjtEditor = (MjtEditor) page.getActiveEditor();
>
> if (mjtEditor == null)
> mjtEditor = (MjtEditor) MjtEditorAdvisor.findEditorPart(
> workbench, getModelURI());
>
> page.activate(mjtEditor);
>
> return mjtEditor;
> }
>
> but then the editor dissapears, the editor here becomes null
>
> Ideas?
>


Ed Merks
Professional Support: https://www.macromodeling.com/
Re: Register EdingDomain as an extenion [message #417007 is a reply to message #416991] Fri, 22 February 2008 16:44 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: cdamus.ca.ibm.com

Hi, Charles, Ed,

The main reason why EMF Transaction component took the
extension-point/registry approach to sharing editing domains amongst
multiple applications was to enable declarative associations of these
editing domains with various other facilities.

One example of this is the org.eclipse.emf.transaction.listeners extension
point. There are other uses of the registry that were intended way back
when but have never materialized.

Cheers,

Christian

Ed Merks wrote:

> Charles,
>
> No. I'm not sure what this would imply. Maybe Christian will
> understand the question better...
>
>
> Charles Martin wrote:
>> Is it possible to register a plain-old EditingDomain as an extension
>> point, in the same this can be done with a TransactionalEditingFactory?
>>
>>
>> Thanks
>>
>> Charles
>>
Re: Register EdingDomain as an extenion [message #417009 is a reply to message #416998] Fri, 22 February 2008 17:10 Go to previous message
Charles H Martin is currently offline Charles H MartinFriend
Messages: 79
Registered: July 2009
Member
Thanks

I really would like to be able to get at the editing Domain before it is selected, or to set it as the default selection, or something liek this

I will probably just punt and keep a global reference somewhere

;)
Previous Topic:[EMF Databinding] should the update strategy handle null?
Next Topic:ChildCreationExtender problem in edit plugin
Goto Forum:
  


Current Time: Thu Apr 25 11:42:16 GMT 2024

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

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

Back to the top