Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 46379 Details for
Bug 150825
No syntax coloring if Ant Editor is associated with different content type or extension
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read
this important communication.
[patch]
Proposed fix.
patch.txt (text/plain), 2.61 KB, created by
Dani Megert
on 2006-07-17 12:55:07 EDT
(
hide
)
Description:
Proposed fix.
Filename:
MIME Type:
Creator:
Dani Megert
Created:
2006-07-17 12:55:07 EDT
Size:
2.61 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.ant.ui >Index: Ant Editor/org/eclipse/ant/internal/ui/editor/text/AntEditorDocumentProvider.java >=================================================================== >RCS file: /home/eclipse/org.eclipse.ant.ui/Ant Editor/org/eclipse/ant/internal/ui/editor/text/AntEditorDocumentProvider.java,v >retrieving revision 1.19 >diff -u -r1.19 AntEditorDocumentProvider.java >--- Ant Editor/org/eclipse/ant/internal/ui/editor/text/AntEditorDocumentProvider.java 23 Jan 2006 18:01:43 -0000 1.19 >+++ Ant Editor/org/eclipse/ant/internal/ui/editor/text/AntEditorDocumentProvider.java 17 Jul 2006 16:58:04 -0000 >@@ -18,18 +18,26 @@ > import org.eclipse.ant.internal.ui.model.AntModel; > import org.eclipse.ant.internal.ui.model.IProblemRequestor; > import org.eclipse.ant.internal.ui.model.LocationProvider; >-import org.eclipse.core.resources.IFile; >+ > import org.eclipse.core.runtime.CoreException; >+ >+import org.eclipse.core.resources.IFile; >+ > import org.eclipse.jface.text.IDocument; >+import org.eclipse.jface.text.IDocumentExtension3; > import org.eclipse.jface.text.ISynchronizable; > import org.eclipse.jface.text.source.IAnnotationModel; >-import org.eclipse.ui.IEditorInput; >+ > import org.eclipse.ui.editors.text.TextFileDocumentProvider; >+ >+import org.eclipse.ui.IEditorInput; > import org.eclipse.ui.texteditor.IDocumentProvider; > > public class AntEditorDocumentProvider extends TextFileDocumentProvider { > >- /** >+ private AntDocumentSetupParticipant fAntDocumentSetupParticipant; >+ >+ /** > * Remembers a Ant document model for each element. > */ > protected class AntFileInfo extends FileInfo { >@@ -43,6 +51,7 @@ > public AntEditorDocumentProvider() { > IDocumentProvider provider= new TextFileDocumentProvider(new AntStorageDocumentProvider()); > setParentDocumentProvider(provider); >+ fAntDocumentSetupParticipant= new AntDocumentSetupParticipant(); > } > > public AntModel getAntModel(Object element) { >@@ -138,4 +147,18 @@ > protected FileInfo createEmptyFileInfo() { > return new AntFileInfo(); > } >+ >+ /* >+ * @see org.eclipse.ui.editors.text.TextFileDocumentProvider#connect(java.lang.Object) >+ * @since 3.3 >+ */ >+ public void connect(Object element) throws CoreException { >+ super.connect(element); >+ IDocument document= getDocument(element); >+ if (document instanceof IDocumentExtension3) { >+ IDocumentExtension3 extension= (IDocumentExtension3) document; >+ if (extension.getDocumentPartitioner(AntDocumentSetupParticipant.ANT_PARTITIONING) == null) >+ fAntDocumentSetupParticipant.setup(document); >+ } >+ } > } >\ No newline at end of file
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 150825
: 46379