Closed
Bug 1432864
Opened 6 years ago
Closed 6 years ago
Marionette interaction commands uses incorrect focussing and unfocussing steps
Categories
(Remote Protocol :: Marionette, enhancement)
Tracking
(firefox59 fixed, firefox60 fixed)
RESOLVED
FIXED
mozilla60
People
(Reporter: ato, Assigned: ato)
References
(Blocks 1 open bug)
Details
Attachments
(8 files)
59 bytes,
text/x-review-board-request
|
automatedtester
:
review+
|
Details |
59 bytes,
text/x-review-board-request
|
automatedtester
:
review+
|
Details |
59 bytes,
text/x-review-board-request
|
automatedtester
:
review+
|
Details |
59 bytes,
text/x-review-board-request
|
automatedtester
:
review+
|
Details |
6.99 KB,
patch
|
Details | Diff | Splinter Review | |
1.95 KB,
patch
|
Details | Diff | Splinter Review | |
7.53 KB,
patch
|
Details | Diff | Splinter Review | |
3.92 KB,
patch
|
Details | Diff | Splinter Review |
Marionette fires custom events from event.focus and event.blur, but doesn’t actually focus or unfocus the element. We can rely on HTMLElement.focus() and HTMLElement.blur() for these operations, which will do the right thing and fire the correct DOM events. A sidenote is that the unfocussing steps especially are difficult to get right without HTMLElement.blur() as there are certain ranges of elements where HTMLElement.focus() will not work for. Also, Gecko does not support its .focus({preventScroll: true}) option.
Comment hidden (mozreview-request) |
Comment hidden (mozreview-request) |
Comment hidden (mozreview-request) |
Comment hidden (mozreview-request) |
Comment hidden (mozreview-request) |
Comment hidden (mozreview-request) |
Comment hidden (mozreview-request) |
Comment hidden (mozreview-request) |
Comment hidden (mozreview-request) |
Comment hidden (mozreview-request) |
Comment 11•6 years ago
|
||
mozreview-review |
Comment on attachment 8945190 [details] Bug 1432864 - Unfocussing steps will target <body> element. https://reviewboard.mozilla.org/r/215426/#review221062 ::: commit-message-6c860:1 (Diff revision 1) > +Bug 1432864 - Unfocussing steps will target the <bdoy> element. r?automatedtester body?
Attachment #8945190 -
Flags: review?(dburns) → review+
Comment 12•6 years ago
|
||
mozreview-review |
Comment on attachment 8945164 [details] Bug 1432864 - Decouple focussing from moving caret in textual form controls. https://reviewboard.mozilla.org/r/215404/#review221078
Attachment #8945164 -
Flags: review?(dburns) → review+
Comment 13•6 years ago
|
||
mozreview-review |
Comment on attachment 8945165 [details] Bug 1432864 - Run native focussing steps on interaction commands. https://reviewboard.mozilla.org/r/215406/#review221080
Attachment #8945165 -
Flags: review?(dburns) → review+
Comment 14•6 years ago
|
||
mozreview-review |
Comment on attachment 8945166 [details] Bug 1432864 - Run unfocussing steps after interaction. https://reviewboard.mozilla.org/r/215408/#review221082
Attachment #8945166 -
Flags: review?(dburns) → review+
Comment hidden (mozreview-request) |
Comment 16•6 years ago
|
||
We're sorry, Autoland could not rebase your commits for you automatically. Please manually rebase your commits and try again. hg error in cmd: hg rebase -s 91bf7dacb5a358e62b9f0e2d2a9e835de5bee32a -d 9218e87c25fb: rebasing 443945:91bf7dacb5a3 "Bug 1432864 - Decouple focussing from moving caret in textual form controls. r=automatedtester" merging testing/marionette/interaction.js rebasing 443946:58366e1c36c0 "Bug 1432864 - Run native focussing steps on interaction commands. r=automatedtester" merging testing/marionette/interaction.js merging testing/web-platform/tests/webdriver/tests/interaction/element_clear.py warning: conflicts while merging testing/marionette/interaction.js! (edit, then use 'hg resolve --mark') warning: conflicts while merging testing/web-platform/tests/webdriver/tests/interaction/element_clear.py! (edit, then use 'hg resolve --mark') unresolved conflicts (see hg resolve, then hg rebase --continue)
Comment hidden (mozreview-request) |
Comment hidden (mozreview-request) |
Comment hidden (mozreview-request) |
Comment hidden (mozreview-request) |
Comment 21•6 years ago
|
||
We're sorry, Autoland could not rebase your commits for you automatically. Please manually rebase your commits and try again. hg error in cmd: hg rebase -s b3c36dffa03c93e14cba7c108f090cfd4c6a5641 -d 9218e87c25fb: rebasing 443949:b3c36dffa03c "Bug 1432864 - Decouple focussing from moving caret in textual form controls. r=automatedtester" merging testing/marionette/interaction.js rebasing 443950:94eb6d3a5b33 "Bug 1432864 - Run native focussing steps on interaction commands. r=automatedtester" merging testing/marionette/interaction.js merging testing/web-platform/tests/webdriver/tests/interaction/element_clear.py warning: conflicts while merging testing/marionette/interaction.js! (edit, then use 'hg resolve --mark') warning: conflicts while merging testing/web-platform/tests/webdriver/tests/interaction/element_clear.py! (edit, then use 'hg resolve --mark') unresolved conflicts (see hg resolve, then hg rebase --continue)
Comment hidden (mozreview-request) |
Comment hidden (mozreview-request) |
Comment hidden (mozreview-request) |
Comment hidden (mozreview-request) |
Comment 26•6 years ago
|
||
Pushed by atolfsen@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/8f2ff0bdb474 Decouple focussing from moving caret in textual form controls. r=automatedtester https://hg.mozilla.org/integration/autoland/rev/00bab9cabf56 Run native focussing steps on interaction commands. r=automatedtester https://hg.mozilla.org/integration/autoland/rev/ea20d86a27d4 Run unfocussing steps after interaction. r=automatedtester https://hg.mozilla.org/integration/autoland/rev/d43aafb30632 Unfocussing steps will target <body> element. r=automatedtester
Comment 27•6 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/8f2ff0bdb474 https://hg.mozilla.org/mozilla-central/rev/00bab9cabf56 https://hg.mozilla.org/mozilla-central/rev/ea20d86a27d4 https://hg.mozilla.org/mozilla-central/rev/d43aafb30632
Status: NEW → RESOLVED
Closed: 6 years ago
status-firefox60:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla60
Assignee | ||
Updated•6 years ago
|
Assignee | ||
Updated•6 years ago
|
Assignee | ||
Comment 28•6 years ago
|
||
Instead of generating custom focus events when interacting with elements, we can run the HTMLElement.focus() function will do the correct thing. Before this patch we only simulated focus events, whereas this patch will actually focus the element. MozReview-Commit-ID: IoBV2ngqOA5
Assignee | ||
Comment 29•6 years ago
|
||
A couple of commands were not running the appropriate unfocussing steps as the WebDriver standards says they should. MozReview-Commit-ID: FyuRvkct19m
Assignee | ||
Comment 30•6 years ago
|
||
The WebDriver Element Send Keys command is meant to run the HTML unfocussing steps after clearing the element. When HTMLElement.blur() is called on the root document element (<html>) it is the <body> that is in focus when the unfocussing steps have run. The same applies in the case of typing into an <iframe> element. The controlling element of the <iframe> is the <body>, as this is the element ath will receive focus should you blur the frame. MozReview-Commit-ID: 19Ox3W9CF8O
Assignee | ||
Comment 31•6 years ago
|
||
Renames the interaction.focusElement, which also happened to move the caret in textual form controls, to interaction.moveCaretToEnd, focussed solely on moving the caret. It doesn't make sense to coalesce these two operations into one function. MozReview-Commit-ID: 2QxV8FllW8J
Assignee | ||
Comment 32•6 years ago
|
||
Sheriffs: Can you please uplift the last four manually uploaded patches? The ordering is: 1. https://bugzilla.mozilla.org/attachment.cgi?id=8947528 2. https://bugzilla.mozilla.org/attachment.cgi?id=8947525 3. https://bugzilla.mozilla.org/attachment.cgi?id=8947526 4. https://bugzilla.mozilla.org/attachment.cgi?id=8947527
Whiteboard: [checkin-needed-beta]
Comment 33•6 years ago
|
||
bugherder uplift |
https://hg.mozilla.org/releases/mozilla-beta/rev/a25a343d7937 https://hg.mozilla.org/releases/mozilla-beta/rev/feae5d29e679 https://hg.mozilla.org/releases/mozilla-beta/rev/cc6e54bee19e https://hg.mozilla.org/releases/mozilla-beta/rev/11887cd21e75
status-firefox59:
--- → fixed
Whiteboard: [checkin-needed-beta]
Updated•6 years ago
|
Updated•1 year ago
|
Product: Testing → Remote Protocol
You need to log in
before you can comment on or make changes to this bug.
Description
•