Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [platform-ant-dev] AntTemplateAccess patch (Ant head requirements)

The patch has been released.

Ant now requires:
    org.eclipse.jface.text
    org.eclipse.ui.editors

Thanks
Darins

----- Original Message ----- 
From: "Darin Swanson" <darinrs@xxxxxxxxxxx>
To: <platform-ant-dev@xxxxxxxxxxx>
Sent: Wednesday, April 28, 2004 12:15 PM
Subject: Re: [platform-ant-dev] AntTemplateAccess patch


> Thanks Tom.
> I have logged bug 60312 to track this change
>
> Darins
>
> ----- Original Message ----- 
> From: "Tom Eicher" <eclipse@xxxxxxxxxxxxxxx>
> To: <platform-ant-dev@xxxxxxxxxxx>
> Sent: Wednesday, April 28, 2004 9:27 AM
> Subject: [platform-ant-dev] AntTemplateAccess patch
>
>
> > Ant Editor team,
> >
> > ContextTypeRegistry and TemplateStore had to be changed because they
> > were layer breakers (the template extension point comes in in ui.editors
> > only!) and because jface.text should not have dependencies on the
> > eclipse plug-in mechanism. See
> > https://bugs.eclipse.org/bugs/show_bug.cgi?id=60258.
> >
> > Attached is a patch that will fix AntTemplateAccess.
> >
> > Sorry for the breakage, Tom
> >
>
>
> --------------------------------------------------------------------------
--
> ----
>
>
> > Index: AntTemplateAccess.java
> > ===================================================================
> > RCS file: /home/eclipse/org.eclipse.ant.ui/Ant
>
Editor/org/eclipse/ant/internal/ui/editor/templates/AntTemplateAccess.java,v
> > retrieving revision 1.3
> > diff -u -r1.3 AntTemplateAccess.java
> > --- AntTemplateAccess.java 25 Apr 2004 16:29:25 -0000 1.3
> > +++ AntTemplateAccess.java 28 Apr 2004 17:26:10 -0000
> > @@ -15,6 +15,8 @@
> >  import org.eclipse.jface.preference.IPreferenceStore;
> >  import org.eclipse.jface.text.templates.ContextTypeRegistry;
> >  import org.eclipse.jface.text.templates.persistence.TemplateStore;
> > +import
> org.eclipse.ui.editors.text.templates.ContributionContextTypeRegistry;
> > +import org.eclipse.ui.editors.text.templates.ContributionTemplateStore;
> >
> >
> >  public class AntTemplateAccess {
> > @@ -28,7 +30,7 @@
> >   private TemplateStore fStore;
> >
> >   /** The context type registry. */
> > - private ContextTypeRegistry fRegistry;
> > + private ContributionContextTypeRegistry fRegistry;
> >
> >   private AntTemplateAccess() {
> >   }
> > @@ -52,7 +54,7 @@
> >   */
> >   public TemplateStore getTemplateStore() {
> >   if (fStore == null) {
> > - fStore= new
>
TemplateStore(getContextTypeRegistry(),AntUIPlugin.getDefault().getPreferenc
> eStore(), CUSTOM_TEMPLATES_KEY);
> > + fStore= new
>
ContributionTemplateStore(getContextTypeRegistry(),AntUIPlugin.getDefault().
> getPreferenceStore(), CUSTOM_TEMPLATES_KEY);
> >   try {
> >   fStore.load();
> >   } catch (IOException e) {
> > @@ -70,7 +72,7 @@
> >   public ContextTypeRegistry getContextTypeRegistry() {
> >   if (fRegistry == null) {
> >   // create and configure the contexts available in the template editor
> > - fRegistry= new ContextTypeRegistry();
> > + fRegistry= new ContributionContextTypeRegistry();
> >   fRegistry.addContextType(BuildFileContextType.BUILDFILE_CONTEXT_TYPE);
> >   fRegistry.addContextType(TaskContextType.TASK_CONTEXT_TYPE);
> >   }
> >
>




Back to the top