@Override
protected void createActions() {
super.createActions();
// Comment
Action action = new TextOperationAction(DLTKEditorMessages.getBundleForConstructedKeys(),
"Comment.", this, ITextOperationTarget.PREFIX); //$NON-NLS-1$
action.setActionDefinitionId(IScriptEditorActionDefinitionIds.COMMENT);
setAction("Comment", action); //$NON-NLS-1$
markAsStateDependentAction("Comment", true); //$NON-NLS-1$
// Uncomment
action = new TextOperationAction(DLTKEditorMessages.getBundleForConstructedKeys(),
"Uncomment.", this, ITextOperationTarget.STRIP_PREFIX); //$NON-NLS-1$
action.setActionDefinitionId(IScriptEditorActionDefinitionIds.UNCOMMENT);
setAction("Uncomment", action); //$NON-NLS-1$
markAsStateDependentAction("Uncomment", true); //$NON-NLS-1$
// Toggle comment
action = new ToggleCommentAction(DLTKEditorMessages.getBundleForConstructedKeys(),
"ToggleComment.", this); //$NON-NLS-1$
action.setActionDefinitionId(IScriptEditorActionDefinitionIds.TOGGLE_COMMENT);
setAction("ToggleComment", action); //$NON-NLS-1$
markAsStateDependentAction("ToggleComment", true); //$NON-NLS-1$
configureToggleCommentAction();
action = new TextOperationAction(DLTKEditorMessages.getBundleForConstructedKeys(),
"Format.", this, ISourceViewer.FORMAT); //$NON-NLS-1$
action.setActionDefinitionId(IScriptEditorActionDefinitionIds.FORMAT);
setAction("Format", action); //$NON-NLS-1$
markAsStateDependentAction("Format", true); //$NON-NLS-1$
markAsSelectionDependentAction("Format", true); //$NON-NLS-1$
// PlatformUI.getWorkbench().getHelpSystem().setHelp(action,
// IJavaHelpContextIds.FORMAT_ACTION);