use of org.eclipse.che.ide.editor.orion.client.OrionEditorPresenter in project che by eclipse.
the class PomEditorProvider method getEditor.
@Override
public TextEditor getEditor() {
TextEditor editor = super.getEditor();
if (editor instanceof OrionEditorPresenter) {
PomEditorConfiguration configuration = configurationFactory.create((OrionEditorPresenter) editor);
editor.initialize(configuration);
}
return editor;
}
use of org.eclipse.che.ide.editor.orion.client.OrionEditorPresenter in project che by eclipse.
the class JsJavaEditorProvider method getEditor.
@Override
public TextEditor getEditor() {
LOG.fine("JsJavaEditor instance creation.");
final TextEditor textEditor = super.getEditor();
if (textEditor instanceof OrionEditorPresenter) {
final OrionEditorPresenter editor = (OrionEditorPresenter) textEditor;
final TextEditorConfiguration configuration = configurationFactory.create(editor);
editor.initialize(configuration);
editor.addEditorUpdateAction(new EditorUpdateAction() {
@Override
public void doRefresh() {
final Reconciler reconciler = configuration.getReconciler();
if (reconciler != null) {
final ReconcilingStrategy strategy = reconciler.getReconcilingStrategy(DEFAULT_CONTENT_TYPE);
if (strategy instanceof JavaReconcilerStrategy) {
((JavaReconcilerStrategy) strategy).parse();
}
}
}
});
}
watcher.editorOpened(textEditor);
return textEditor;
}
use of org.eclipse.che.ide.editor.orion.client.OrionEditorPresenter in project che by eclipse.
the class RecipeEditorPanel method getEditor.
private TextEditor getEditor() {
OrionEditorPresenter editor = orionTextEditorFactory.get();
editor.initialize(new DefaultTextEditorConfiguration());
return editor;
}
Aggregations