IEditorPart editorPart = this.getActiveEditor();
if (editorPart == null || !(this.getActiveEditor() instanceof ITextEditor)) {
return;
}
ITextEditor textEditor = (ITextEditor) editorPart;
textEditor.doRevertToSaved();
}
public void setAction(String actionID, IAction action) {
IEditorPart editorPart = this.getActiveEditor();
if (editorPart == null || !(this.getActiveEditor() instanceof ITextEditor)) {