jenkins-bot has submitted this change and it was merged.

Change subject: Don't fix selection on document focus if focusedNode is set
......................................................................


Don't fix selection on document focus if focusedNode is set

Bug: 65866
Change-Id: Iff018d7809b6dfbb0bc831b4eb25607b4c724b76
---
M modules/ve/ce/ve.ce.Surface.js
1 file changed, 3 insertions(+), 1 deletion(-)

Approvals:
  Trevor Parscal: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/modules/ve/ce/ve.ce.Surface.js b/modules/ve/ce/ve.ce.Surface.js
index 528c13d..dd90de6 100644
--- a/modules/ve/ce/ve.ce.Surface.js
+++ b/modules/ve/ce/ve.ce.Surface.js
@@ -406,7 +406,9 @@
  * @fires focus
  */
 ve.ce.Surface.prototype.onDocumentFocus = function () {
-       if ( !this.dragging ) {
+       // this.dragging is set when the mouse is down, but not on focusable
+       // nodes so check this.focusedNode as well
+       if ( !this.dragging && !this.focusedNode ) {
                // If the document is being focused by a non-mouse user event, 
FF may place
                // the cursor in a non-content offset (i.e. just after the 
document div), so
                // find the first content offset instead.

-- 
To view, visit https://gerrit.wikimedia.org/r/136013
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Iff018d7809b6dfbb0bc831b4eb25607b4c724b76
Gerrit-PatchSet: 2
Gerrit-Project: VisualEditor/VisualEditor
Gerrit-Branch: master
Gerrit-Owner: Esanders <[email protected]>
Gerrit-Reviewer: Catrope <[email protected]>
Gerrit-Reviewer: Krinkle <[email protected]>
Gerrit-Reviewer: Trevor Parscal <[email protected]>
Gerrit-Reviewer: jenkins-bot <>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to