Skip to content

Commit

Permalink
Extend fileCreator extension point with description attribute
Browse files Browse the repository at this point in the history
The description attribute is needed for the quick access component of
Eclipse.
  • Loading branch information
kiritsuku authored and Luc Bourlier committed Jul 15, 2014
1 parent 7a1ce6d commit bebad06
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 16 deletions.
5 changes: 5 additions & 0 deletions org.scala-ide.sdt.core/plugin.xml
Original file line number Diff line number Diff line change
Expand Up @@ -1620,34 +1620,39 @@
point="org.scala-ide.sdt.core.fileCreator">
<fileCreator
class="org.scalaide.ui.wizards.ClassCreator"
description="Create a Scala Class"
icon="icons/full/etool16/newclass_wiz.gif"
id="org.scalaide.ui.wizards.classCreator"
name="Scala Class"
templateId="org.scalaide.core.templates.wizards.class">
</fileCreator>
<fileCreator
class="org.scalaide.ui.wizards.TraitCreator"
description="Create a Scala Trait"
icon="icons/full/etool16/newtrait_wiz.gif"
id="org.scalaide.ui.wizards.traitCreator"
name="Scala Trait"
templateId="org.scalaide.core.templates.wizards.trait">
</fileCreator>
<fileCreator
class="org.scalaide.ui.wizards.ObjectCreator"
description="Create a Scala Object"
icon="icons/full/etool16/newobject_wiz.gif"
id="org.scalaide.ui.wizards.objectCreator"
name="Scala Object"
templateId="org.scalaide.core.templates.wizards.object">
</fileCreator>
<fileCreator
class="org.scalaide.ui.wizards.PackageObjectCreator"
description="Create a Scala Package Object"
icon="icons/full/etool16/newpackage_object_wiz.png"
id="org.scalaide.ui.wizards.packageObjectCreator"
name="Scala Package Object"
templateId="org.scalaide.core.templates.wizards.packageObject">
</fileCreator>
<fileCreator
class="org.scalaide.ui.wizards.AppCreator"
description="Create a Scala App"
icon="icons/full/etool16/scala_app.gif"
id="org.scalaide.ui.wizards.appCreator"
name="Scala App"
Expand Down
39 changes: 23 additions & 16 deletions org.scala-ide.sdt.core/schema/fileCreator.exsd
Original file line number Diff line number Diff line change
Expand Up @@ -2,19 +2,19 @@
<!-- Schema file written by PDE -->
<schema targetNamespace="org.scala-ide.sdt.core" xmlns="http://www.w3.org/2001/XMLSchema">
<annotation>
<appinfo>
<appInfo>
<meta.schema plugin="org.scala-ide.sdt.core" id="fileCreator" name="File Creator"/>
</appinfo>
</appInfo>
<documentation>
File creator that appears as choice in the new file wizard. The new file wizard creates files based on templates, this means that each file creator also needs to provide a template.
</documentation>
</annotation>

<element name="extension">
<annotation>
<appinfo>
<appInfo>
<meta.element />
</appinfo>
</appInfo>
</annotation>
<complexType>
<choice minOccurs="1" maxOccurs="unbounded">
Expand All @@ -39,9 +39,9 @@
<documentation>

</documentation>
<appinfo>
<appInfo>
<meta.attribute translatable="true"/>
</appinfo>
</appInfo>
</annotation>
</attribute>
</complexType>
Expand All @@ -68,9 +68,9 @@
<documentation>
A fully qualified name of the class implementing org.scalaide.ui.wizards.FileCreator.
</documentation>
<appinfo>
<appInfo>
<meta.attribute kind="java" basedOn=":org.scalaide.ui.wizards.FileCreator"/>
</appinfo>
</appInfo>
</annotation>
</attribute>
<attribute name="templateId" type="string" use="required">
Expand All @@ -85,36 +85,43 @@
<documentation>
A relative path to an icon that will be used together with the name to represent this file creator as one of the choices in the wizard.
</documentation>
<appinfo>
<appInfo>
<meta.attribute kind="resource"/>
</appinfo>
</appInfo>
</annotation>
</attribute>
<attribute name="description" type="string" use="required">
<annotation>
<documentation>

</documentation>
</annotation>
</attribute>
</complexType>
</element>

<annotation>
<appinfo>
<appInfo>
<meta.section type="since"/>
</appinfo>
</appInfo>
<documentation>
Scala IDE 4.0
</documentation>
</annotation>

<annotation>
<appinfo>
<appInfo>
<meta.section type="examples"/>
</appinfo>
</appInfo>
<documentation>
For an example on how to implement your own file creator see the interface org.scalaide.ui.wizards.ScalaFileCreator.
</documentation>
</annotation>

<annotation>
<appinfo>
<appInfo>
<meta.section type="apiinfo"/>
</appinfo>
</appInfo>
<documentation>
See the interface org.scalaide.ui.wizards.FileCreator for more information on how to implement a file creator.
</documentation>
Expand Down

0 comments on commit bebad06

Please sign in to comment.