Skip to content

Conversation

@dotta
Copy link
Member

@dotta dotta commented Apr 3, 2013

Java Play2 Template project don't have the Scala nature by default, and this
caused an exception to be thrown whenever the user tried to open a Play2
Template editor because the editor needs access to the ScalaProject
facilities.

The implemented solution is to automatically add the Scala nature if a project
doesn't have it.

Note that TemplateCompilationUnit.scalaProject is no longer lazy
because I want the code to fail fast if a ScalaProject cannot be created.

Fix #33

dotta added 3 commits April 3, 2013 14:02
Java Play2 Template project don't have the Scala nature by default, and this
caused an exception to be thrown whenever the user tried to open a Play2
Template editor because the editor needs access to the ``ScalaProject``
facilities.

The implemented solution is to automatically add the Scala nature if a project
doesn't have it.

Note that ``TemplateCompilationUnit.scalaProject`` is no longer ``lazy``
because I want the code to fail fast if a ``ScalaProject`` cannot be created.

Fix scala-ide#33
* Removed unused import in ``RouteTestSuite``.
* Added explicit return type on public methods.
* Remove comment in POM about Play 2.0.x support.
@dragos
Copy link
Member

dragos commented Apr 4, 2013

LGTM

dotta added a commit that referenced this pull request Apr 4, 2013
 Automatically add Scala nature when opening Play2 Template editor
@dotta dotta merged commit c664235 into scala-ide:master Apr 4, 2013
@dotta dotta deleted the issue/detect-missing-scala-nature-33 branch April 4, 2013 08:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

"Failed to create the part's controls" when opening template with Template editor

2 participants