mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/VisualEditor
synced 2024-11-15 10:35:48 +00:00
Normalize selection before use!
This commit is contained in:
parent
f9ad5bed54
commit
85526a7d46
|
@ -64,6 +64,7 @@ es.SurfaceModel.prototype.getSelection = function() {
|
|||
* @param {Boolean} combine Whether to prevent this transaction from causing a state push
|
||||
*/
|
||||
es.SurfaceModel.prototype.select = function( selection, combine ) {
|
||||
selection.normalize();
|
||||
if ( !combine && this.shouldPushState( selection ) ) {
|
||||
this.pushState();
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue