ITextEditor textEditor= null;
if (part instanceof ITextEditor)
textEditor= (ITextEditor) part;
/** The global actions to be connected with editor actions */
IActionBars actionBars= getActionBars();
actionBars.setGlobalActionHandler(IDEActionFactory.ADD_TASK.getId(), getAction(textEditor, IDEActionFactory.ADD_TASK.getId()));
actionBars.setGlobalActionHandler(IDEActionFactory.BOOKMARK.getId(), getAction(textEditor, IDEActionFactory.BOOKMARK.getId()));
IAction action= getAction(textEditor, ITextEditorActionConstants.NEXT);
actionBars.setGlobalActionHandler(ITextEditorActionDefinitionIds.GOTO_NEXT_ANNOTATION, action);
actionBars.setGlobalActionHandler(ITextEditorActionConstants.NEXT, action);
action= getAction(textEditor, ITextEditorActionConstants.PREVIOUS);
actionBars.setGlobalActionHandler(ITextEditorActionDefinitionIds.GOTO_PREVIOUS_ANNOTATION, action);
actionBars.setGlobalActionHandler(ITextEditorActionConstants.PREVIOUS, action);
action= getAction(textEditor, ActionFactory.REFRESH.getId());
actionBars.setGlobalActionHandler(ActionFactory.REFRESH.getId(), action);
fChangeEncodingAction.setAction(getAction(textEditor, ITextEditorActionConstants.CHANGE_ENCODING));
IAction quickAssistAction= getAction(textEditor, ITextEditorActionConstants.QUICK_ASSIST);
fQuickAssistAction.setAction(quickAssistAction);