Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF » [EMF Forms] Custom controls are not working
[EMF Forms] Custom controls are not working [message #1696412] Tue, 26 May 2015 11:07 Go to next message
Tobias Zangl is currently offline Tobias ZanglFriend
Messages: 15
Registered: May 2015
Junior Member
Hey,

i tried your tutorial about custom controls in the view model (eclipsesource: blogs/tutorials/emf-forms-custom-control-areas/) but i am not able to get it to work.

I created all the files as mentioned and in the view model editor i also added a custom control with the bundle+class name. It is not showing any errors but i guess it is not validating anywhere if the class file can be found? Because if i use an arbitrary class name it is also not showing any errors.

The Domain model reference value is not shown, only a little linked-icon is displayed and again, no error messages anywhere.

The view model part as text:
  <children xsi:type="org.eclipse.emf.ecp.view.custom.model:CustomControl" name="custom" bundleName="org.eclipse.emf.ecp.view.custom.ui.swt.example" className="org.eclipse.emf.ecp.view.custom.ui.swt.example.MyCustomControl">
    <domainModelReference xsi:type="org.eclipse.emf.ecp.view.custom.model:CustomDomainModelReference" bundleName="org.eclipse.emf.ecp.view.custom.ui.swt.example" className="org.eclipse.emf.ecp.view.custom.ui.swt.example.MyCustomDomainModelReference"/>
  </children>


The custom control is not shown in the preview editor nor in the launched application and my debug-messages inserted in the renderControl and getNeededDomainModelReferences methods are not shown in the console either.

Is the tutorial outdated? (SWTControl.class is marked as deprecated for example)

Any ideas or hints why it is not working?

Greetings,
Tobi
Re: [EMF Forms] Custom controls are not working [message #1696433 is a reply to message #1696412] Tue, 26 May 2015 13:12 Go to previous messageGo to next message
Lucas Koehler is currently offline Lucas KoehlerFriend
Messages: 2
Registered: May 2014
Junior Member
Hi Tobias,

I redid the tutorial and it worked for me. Did you make sure to add the plugins containing the custom control the view model to the run configuration? This is necessary but not mentioned in the tutorial.

Greetings,
Lucas
Re: [EMF Forms] Custom controls are not working [message #1696579 is a reply to message #1696433] Wed, 27 May 2015 11:17 Go to previous message
Tobias Zangl is currently offline Tobias ZanglFriend
Messages: 15
Registered: May 2015
Junior Member
Hey Lucas,

thanks for your response. Looks like that was one of the problems.
The other one was that i have put the custom stuff in a package into my other plugin stuff and not into a new java plugin project. Looks like this messes something up with the bundle declaration in the view model file?

Anyway thanks, it works fine now. Smile

Greetings,
Tobi
Previous Topic:[EMF] How to use container the right way
Next Topic:Are there any guideline when making a meta model with EMF?
Goto Forum:
  


Current Time: Fri Oct 18 09:26:03 GMT 2019

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

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

Back to the top