Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF "Technology" (Ecore Tools, EMFatic, etc)  » [ECP] Custom Editor Form
[ECP] Custom Editor Form [message #1711696] Mon, 19 October 2015 10:54 Go to next message
Wim Jongman is currently offline Wim JongmanFriend
Messages: 456
Registered: July 2009
Senior Member

Hi,

I have created a new custom form based on this tutorial [1]. However, if I include my new viewmodel plugin it does not pickup the new form but shows the Standard View editor instead.

I have made sure that:

* Custom forms render well in preview
* extension points were generated that point to custom models
* model, edit and view model plugins are included in run config

I was hoping that the custom forms would automatically override the reflective forms. Do I have to do something special in order for the custom view model to be picked up?

Cheers and thanks for taking the time to answer,

Wim

[1] http://eclipsesource.com/blogs/tutorials/getting-started-with-EMF-Forms/

[Updated on: Mon, 19 October 2015 10:55]

Report message to a moderator

Re: Customer Editor Form [message #1711734 is a reply to message #1711696] Mon, 19 October 2015 13:07 Go to previous messageGo to next message
Jonas Helming is currently offline Jonas HelmingFriend
Messages: 699
Registered: July 2009
Senior Member
Hi Wim,

no you do not have to do something sepcial. However, what do you mean by
"Standard View editor"?

Best regards

Jonas


Am 19.10.2015 um 12:54 schrieb Wim Jongman:
> Hi,
>
> I have created a new custom form based on this tutorial [1]. However, if
> I include my new viewmodel plugin it does not pickup the new form but
> shows the Standard View editor instead.
>
> I have made sure that:
>
> * Custom forms render well in preview
> * extension points were generated that point to custom models
> * model, edit and view model plugins are included in run config
>
> I was hoping that the custom forms would automatically override the
> reflective forms. Do I have to do something special in order for the
> custom view model to be picked up?
>
> Cheers and thanks for taking the time to answer,
>
> Wim
>
> [1]
> http://eclipsesource.com/blogs/tutorials/getting-started-with-EMF-Forms/
>


--
--

Jonas Helming

Get professional Eclipse developer support:

http://eclipsesource.com/en/services/developer-support/
Re: Custom Editor Form [message #1711749 is a reply to message #1711734] Mon, 19 October 2015 13:53 Go to previous messageGo to next message
Wim Jongman is currently offline Wim JongmanFriend
Messages: 456
Registered: July 2009
Senior Member

index.php/fa/23610/0/

This view.
Re: Custom Editor Form [message #1711827 is a reply to message #1711749] Tue, 20 October 2015 05:21 Go to previous messageGo to next message
Jonas Helming is currently offline Jonas HelmingFriend
Messages: 699
Registered: July 2009
Senior Member
Hi Wim,

should acually work from scratch. Hard to say what wents wron, if there
is not error. Could you actually try to add the "make it happen" model
from the tutorial including its view model to your run config and see
whether it works for them?
Have you created your run config following the tutorial?

Best regards

Jonas


Am 19.10.2015 um 15:53 schrieb Wim Jongman:
> This view.
>


--
--

Jonas Helming

Get professional Eclipse developer support:

http://eclipsesource.com/en/services/developer-support/
Re: Custom Editor Form [message #1711872 is a reply to message #1711827] Tue, 20 October 2015 08:22 Go to previous messageGo to next message
Wim Jongman is currently offline Wim JongmanFriend
Messages: 456
Registered: July 2009
Senior Member

Hi Jonas,

Thanks. I just wanted to make sure. i will go over everything again and post my findings here.

Cheers,

Wim
Re: Custom Editor Form [message #1711952 is a reply to message #1711872] Tue, 20 October 2015 12:05 Go to previous messageGo to next message
Wim Jongman is currently offline Wim JongmanFriend
Messages: 456
Registered: July 2009
Senior Member

Hi,

I have debugged the model bootstrapping process and I have found the reason that my custom form is not used. The ViewModelExtensionManager is registering the model under EObject "Application" but when the ECP RCP asks for a custom model ExtensionXMIViewModelProvider is querying with "ApplicationImpl". This returns NOT_APPLICABLE (-1.0) and the reflective form viewer is activated.

Just wanted to report that l have found the cause. Now I will start looking for the solution.

Cheers,

Wim

[Updated on: Tue, 20 October 2015 12:05]

Report message to a moderator

Re: Custom Editor Form [message #1712010 is a reply to message #1711952] Tue, 20 October 2015 17:40 Go to previous messageGo to next message
Wim Jongman is currently offline Wim JongmanFriend
Messages: 456
Registered: July 2009
Senior Member

Turns out that when you use subpackages in your ecore the custom view model is not picked up. I did a toe to toe comparison of the two models (example model for makeithappen and my own model) and in the end had nothing left to try but to remove my subpackages. Sure enough that was the problem.

Is this as designed or should I file an issue?

Cheers,

Wim
Re: Custom Editor Form [message #1712017 is a reply to message #1712010] Tue, 20 October 2015 18:17 Go to previous messageGo to next message
Jonas Helming is currently offline Jonas HelmingFriend
Messages: 699
Registered: July 2009
Senior Member
Hi Wim,

that could potentially be an issue, please see here:
http://eclipsesource.com/blogs/2013/03/19/emf-dos-and-don%C2%B4ts-5/
:-)
If you want, you can file a BR, though...

Best regards

Jonas


Am 20.10.2015 um 19:40 schrieb Wim Jongman:
> Turns out that when you use subpackages in your ecore the custom view
> model is not picked up. I did a toe to toe comparison of the two models
> (example model for makeithappen and my own model) and in the end had
> nothing left to try but to remove my subpackages. Sure enough that was
> the problem.
>
> Is this as designed or should I file an issue?
>
> Cheers,
>
> Wim


--
--

Jonas Helming

Get professional Eclipse developer support:

http://eclipsesource.com/en/services/developer-support/
Re: Custom Editor Form [message #1712021 is a reply to message #1712017] Tue, 20 October 2015 18:49 Go to previous message
Wim Jongman is currently offline Wim JongmanFriend
Messages: 456
Registered: July 2009
Senior Member

"Developers of EMF-based frameworks sometimes forget to correctly address the special case of sub-packages."

That is classic! Very Happy

I have filed a bug [1]

Thanks,

Wim

[1] https://bugs.eclipse.org/bugs/show_bug.cgi?id=480247
Previous Topic:[EEF] Using EEF in a dialog window
Next Topic:[EMF Forms] constraints for unsettable=true and lowerBound=1
Goto Forum:
  


Current Time: Sun Dec 06 00:32:19 GMT 2020

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

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

Back to the top