diff --git a/modules/ve/ui/actions/ve.ui.DialogAction.js b/modules/ve/ui/actions/ve.ui.DialogAction.js index b65c75eb3b..e1a7aa21c2 100644 --- a/modules/ve/ui/actions/ve.ui.DialogAction.js +++ b/modules/ve/ui/actions/ve.ui.DialogAction.js @@ -37,7 +37,7 @@ ve.ui.DialogAction.static.methods = [ 'open' ]; /* Methods */ /** - * Open an Dialog. + * Open a Dialog. * * @method * @param {string} name Symbolic name of Dialog to open diff --git a/modules/ve/ui/ve.ui.CommandRegistry.js b/modules/ve/ui/ve.ui.CommandRegistry.js index 9b472cacac..d418cff438 100644 --- a/modules/ve/ui/ve.ui.CommandRegistry.js +++ b/modules/ve/ui/ve.ui.CommandRegistry.js @@ -48,6 +48,12 @@ ve.ui.commandRegistry = new ve.ui.CommandRegistry(); /* Registrations */ +ve.ui.commandRegistry.register( + 'undo', new ve.ui.Command( 'history', 'undo' ) +); +ve.ui.commandRegistry.register( + 'redo', new ve.ui.Command( 'history', 'redo' ) +); ve.ui.commandRegistry.register( 'bold', new ve.ui.Command( 'annotation', 'toggle', 'textStyle/bold' ) ); @@ -55,10 +61,10 @@ ve.ui.commandRegistry.register( 'italic', new ve.ui.Command( 'annotation', 'toggle', 'textStyle/italic' ) ); ve.ui.commandRegistry.register( - 'code', new ve.ui.Command( 'annotation', 'toggle', 'textStyle/code' ) + 'link', new ve.ui.Command( 'inspector', 'open', 'link' ) ); ve.ui.commandRegistry.register( - 'strikethrough', new ve.ui.Command( 'annotation', 'toggle', 'textStyle/strike' ) + 'clear', new ve.ui.Command( 'annotation', 'clearAll' ) ); ve.ui.commandRegistry.register( 'underline', new ve.ui.Command( 'annotation', 'toggle', 'textStyle/underline' ) @@ -69,9 +75,6 @@ ve.ui.commandRegistry.register( ve.ui.commandRegistry.register( 'superscript', new ve.ui.Command( 'annotation', 'toggle', 'textStyle/superscript' ) ); -ve.ui.commandRegistry.register( - 'clear', new ve.ui.Command( 'annotation', 'clearAll' ) -); ve.ui.commandRegistry.register( 'indent', new ve.ui.Command( 'indentation', 'increase' ) ); @@ -79,17 +82,14 @@ ve.ui.commandRegistry.register( 'outdent', new ve.ui.Command( 'indentation', 'decrease' ) ); ve.ui.commandRegistry.register( - 'link', new ve.ui.Command( 'inspector', 'open', 'link' ) + 'code', new ve.ui.Command( 'annotation', 'toggle', 'textStyle/code' ) +); +ve.ui.commandRegistry.register( + 'strikethrough', new ve.ui.Command( 'annotation', 'toggle', 'textStyle/strike' ) ); ve.ui.commandRegistry.register( 'language', new ve.ui.Command( 'inspector', 'open', 'language' ) ); -ve.ui.commandRegistry.register( - 'redo', new ve.ui.Command( 'history', 'redo' ) -); -ve.ui.commandRegistry.register( - 'undo', new ve.ui.Command( 'history', 'undo' ) -); ve.ui.commandRegistry.register( 'paragraph', new ve.ui.Command( 'format', 'convert', 'paragraph' ) );