mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-09-04 22:23:28 +02:00
Remove obsolete constant
This commit is contained in:
parent
013b7794ef
commit
5cada17513
2 changed files with 39 additions and 37 deletions
|
@ -31,10 +31,6 @@ import org.eclipse.ui.texteditor.TextOperationAction;
|
||||||
import org.eclipse.ui.views.contentoutline.IContentOutlinePage;
|
import org.eclipse.ui.views.contentoutline.IContentOutlinePage;
|
||||||
|
|
||||||
public class MakefileEditor extends TextEditor {
|
public class MakefileEditor extends TextEditor {
|
||||||
public final static String MAKE_COMMENT = "make_comment"; //$NON-NLS-1$
|
|
||||||
public final static String MAKE_KEYWORD = "make_keyword"; //$NON-NLS-1$
|
|
||||||
public final static String MAKE_MACRO_VAR = "macro_var"; //$NON-NLS-1$
|
|
||||||
public final static String MAKE_META_DATA = "meta_data"; //$NON-NLS-1$
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The page that shows the outline.
|
* The page that shows the outline.
|
||||||
|
|
|
@ -58,31 +58,37 @@ public class MakefileSourceConfiguration extends SourceViewerConfiguration {
|
||||||
public String[] getConfiguredContentTypes(ISourceViewer v) {
|
public String[] getConfiguredContentTypes(ISourceViewer v) {
|
||||||
return new String[] {
|
return new String[] {
|
||||||
IDocument.DEFAULT_CONTENT_TYPE,
|
IDocument.DEFAULT_CONTENT_TYPE,
|
||||||
MakefileEditor.MAKE_COMMENT,
|
MakefilePartitionScanner.MAKEFILE_COMMENT,//MakefileEditor.MAKE_COMMENT,
|
||||||
MakefileEditor.MAKE_KEYWORD,
|
MakefilePartitionScanner.MAKEFILE_IF_BLOCK,//MakefileEditor.MAKE_KEYWORD,
|
||||||
MakefileEditor.MAKE_MACRO_VAR,
|
MakefilePartitionScanner.MAKEFILE_DEF_BLOCK,
|
||||||
MakefileEditor.MAKE_META_DATA
|
MakefilePartitionScanner.MAKEFILE_INCLUDE_BLOCK,
|
||||||
};
|
MakefilePartitionScanner.MAKEFILE_MACRO_ASSIGNEMENT, //MakefileEditor.MAKE_MACRO_VAR,
|
||||||
|
};//MakefileEditor.MAKE_META_DATA };
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @see org.eclipse.jface.text.source.SourceViewerConfiguration#getContentAssistant(ISourceViewer)
|
* @see org.eclipse.jface.text.source.SourceViewerConfiguration#getContentAssistant(ISourceViewer)
|
||||||
*/
|
*/
|
||||||
public IContentAssistant getContentAssistant(ISourceViewer sourceViewer) {
|
public IContentAssistant getContentAssistant(ISourceViewer sourceViewer) {
|
||||||
ContentAssistant assistant = new ContentAssistant();
|
ContentAssistant assistant = new ContentAssistant();
|
||||||
assistant.setContentAssistProcessor(new MakefileCompletionProcessor(fEditor), IDocument.DEFAULT_CONTENT_TYPE);
|
assistant.setContentAssistProcessor(new MakefileCompletionProcessor(fEditor), IDocument.DEFAULT_CONTENT_TYPE);
|
||||||
assistant.setContentAssistProcessor(new MakefileCompletionProcessor(fEditor), MakefileEditor.MAKE_MACRO_VAR);
|
assistant.setContentAssistProcessor(new MakefileCompletionProcessor(fEditor), MakefilePartitionScanner.MAKEFILE_COMMENT);
|
||||||
assistant.enableAutoActivation(true);
|
assistant.setContentAssistProcessor(new MakefileCompletionProcessor(fEditor), MakefilePartitionScanner.MAKEFILE_DEF_BLOCK);
|
||||||
assistant.setAutoActivationDelay(500);
|
assistant.setContentAssistProcessor(new MakefileCompletionProcessor(fEditor), MakefilePartitionScanner.MAKEFILE_IF_BLOCK);
|
||||||
assistant.setProposalPopupOrientation(IContentAssistant.CONTEXT_INFO_BELOW);
|
assistant.setContentAssistProcessor(new MakefileCompletionProcessor(fEditor), MakefilePartitionScanner.MAKEFILE_INCLUDE_BLOCK);
|
||||||
assistant.setContextInformationPopupOrientation(IContentAssistant.CONTEXT_INFO_BELOW);
|
assistant.setContentAssistProcessor(new MakefileCompletionProcessor(fEditor), MakefilePartitionScanner.MAKEFILE_MACRO_ASSIGNEMENT);
|
||||||
//Set to Carolina blue
|
|
||||||
assistant.setContextInformationPopupBackground(getColorManager().getColor(new RGB(0, 191, 255)));
|
|
||||||
|
|
||||||
return assistant;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
assistant.enableAutoActivation(true);
|
||||||
|
assistant.setAutoActivationDelay(500);
|
||||||
|
|
||||||
|
assistant.setProposalPopupOrientation(IContentAssistant.CONTEXT_INFO_BELOW);
|
||||||
|
assistant.setContextInformationPopupOrientation(IContentAssistant.CONTEXT_INFO_BELOW);
|
||||||
|
//Set to Carolina blue
|
||||||
|
assistant.setContextInformationPopupBackground(getColorManager().getColor(new RGB(0, 191, 255)));
|
||||||
|
|
||||||
|
return assistant;
|
||||||
|
}
|
||||||
|
|
||||||
protected IMakefileColorManager getColorManager() {
|
protected IMakefileColorManager getColorManager() {
|
||||||
if (null == colorManager)
|
if (null == colorManager)
|
||||||
|
@ -107,28 +113,28 @@ public class MakefileSourceConfiguration extends SourceViewerConfiguration {
|
||||||
|
|
||||||
dr = new DefaultDamagerRepairer(getCodeScanner());
|
dr = new DefaultDamagerRepairer(getCodeScanner());
|
||||||
dr = new DefaultDamagerRepairer(getCodeScanner());
|
dr = new DefaultDamagerRepairer(getCodeScanner());
|
||||||
reconciler.setDamager(dr, MakefilePartitionScanner.MAKE_COMMENT);
|
reconciler.setDamager(dr, MakefilePartitionScanner.MAKEFILE_COMMENT);
|
||||||
reconciler.setRepairer(dr, MakefilePartitionScanner.MAKE_COMMENT);
|
reconciler.setRepairer(dr, MakefilePartitionScanner.MAKEFILE_COMMENT);
|
||||||
|
|
||||||
dr = new DefaultDamagerRepairer(getCodeScanner());
|
dr = new DefaultDamagerRepairer(getCodeScanner());
|
||||||
reconciler.setDamager(dr, MakefilePartitionScanner.MAKE_MACRO_ASSIGNEMENT);
|
reconciler.setDamager(dr, MakefilePartitionScanner.MAKEFILE_MACRO_ASSIGNEMENT);
|
||||||
reconciler.setRepairer(dr, MakefilePartitionScanner.MAKE_MACRO_ASSIGNEMENT);
|
reconciler.setRepairer(dr, MakefilePartitionScanner.MAKEFILE_MACRO_ASSIGNEMENT);
|
||||||
|
|
||||||
dr = new DefaultDamagerRepairer(getCodeScanner());
|
dr = new DefaultDamagerRepairer(getCodeScanner());
|
||||||
reconciler.setDamager(dr, MakefilePartitionScanner.MAKE_INCLUDE_BLOCK);
|
reconciler.setDamager(dr, MakefilePartitionScanner.MAKEFILE_INCLUDE_BLOCK);
|
||||||
reconciler.setRepairer(dr, MakefilePartitionScanner.MAKE_INCLUDE_BLOCK);
|
reconciler.setRepairer(dr, MakefilePartitionScanner.MAKEFILE_INCLUDE_BLOCK);
|
||||||
|
|
||||||
dr = new DefaultDamagerRepairer(getCodeScanner());
|
dr = new DefaultDamagerRepairer(getCodeScanner());
|
||||||
reconciler.setDamager(dr, MakefilePartitionScanner.MAKE_IF_BLOCK);
|
reconciler.setDamager(dr, MakefilePartitionScanner.MAKEFILE_IF_BLOCK);
|
||||||
reconciler.setRepairer(dr, MakefilePartitionScanner.MAKE_IF_BLOCK);
|
reconciler.setRepairer(dr, MakefilePartitionScanner.MAKEFILE_IF_BLOCK);
|
||||||
|
|
||||||
dr = new DefaultDamagerRepairer(getCodeScanner());
|
dr = new DefaultDamagerRepairer(getCodeScanner());
|
||||||
reconciler.setDamager(dr, MakefilePartitionScanner.MAKE_DEF_BLOCK);
|
reconciler.setDamager(dr, MakefilePartitionScanner.MAKEFILE_DEF_BLOCK);
|
||||||
reconciler.setRepairer(dr, MakefilePartitionScanner.MAKE_DEF_BLOCK);
|
reconciler.setRepairer(dr, MakefilePartitionScanner.MAKEFILE_DEF_BLOCK);
|
||||||
|
|
||||||
dr = new DefaultDamagerRepairer(getCodeScanner());
|
dr = new DefaultDamagerRepairer(getCodeScanner());
|
||||||
reconciler.setDamager(dr, MakefilePartitionScanner.MAKE_OTHER);
|
reconciler.setDamager(dr, MakefilePartitionScanner.MAKEFILE_OTHER);
|
||||||
reconciler.setRepairer(dr, MakefilePartitionScanner.MAKE_OTHER);
|
reconciler.setRepairer(dr, MakefilePartitionScanner.MAKEFILE_OTHER);
|
||||||
return reconciler;
|
return reconciler;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue