Changeset 268867 in webkit
- Timestamp:
- Oct 22, 2020 9:01:40 AM (21 months ago)
- Location:
- trunk/Source
- Files:
-
- 4 edited
-
WebDriver/ChangeLog (modified) (1 diff)
-
WebDriver/Session.cpp (modified) (2 diffs)
-
WebKit/ChangeLog (modified) (1 diff)
-
WebKit/WebProcess/Automation/WebAutomationSessionProxy.js (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebDriver/ChangeLog
r268793 r268867 1 2020-10-22 Nitzan Uziely <linkgoron@gmail.com> 2 3 Elements in Shadow DOM are wrongly marked as stale by the WebDriver 4 https://bugs.webkit.org/show_bug.cgi?id=217635 5 6 Reviewed by Brian Burg. 7 8 Changed stale checking, to check if the root node is the document element, 9 instead of document.contains which doesn't work for elements in Shadow DOM. 10 11 * Session.cpp: 12 (WebDriver::Session::elementSendKeys): 13 1 14 2020-10-21 Carlos Garcia Campos <cgarcia@igalia.com> 2 15 -
trunk/Source/WebDriver/Session.cpp
r268793 r268867 2095 2095 " let doc = element.ownerDocument || element;" 2096 2096 " let prevActiveElement = doc.activeElement;" 2097 " if (element != prevActiveElement && prevActiveElement)" 2097 " let elementRootNode = element.getRootNode();" 2098 " if (elementRootNode.activeElement !== element && prevActiveElement)" 2098 2099 " prevActiveElement.blur();" 2099 2100 " element.focus();" … … 2104 2105 " if (isTextElement && element.selectionEnd == 0)" 2105 2106 " element.setSelectionRange(element.value.length, element.value.length);" 2106 " if (element != doc.activeElement)"2107 " if (elementRootNode.activeElement !== element)" 2107 2108 " throw {name: 'ElementNotInteractable', message: 'Element is not focusable.'};" 2108 2109 "}"; -
trunk/Source/WebKit/ChangeLog
r268866 r268867 1 2020-10-22 Nitzan Uziely <linkgoron@gmail.com> 2 3 Elements in Shadow DOM are wrongly marked as stale by the WebDriver 4 https://bugs.webkit.org/show_bug.cgi?id=217635 5 6 Reviewed by Brian Burg. 7 8 Fixed the focus script to work for elements in Shadow DOM 9 instead of declaring them as not interactable. 10 11 * WebProcess/Automation/WebAutomationSessionProxy.js: 12 (let.AutomationSessionProxy.prototype._clearStaleNodes): 13 (let.AutomationSessionProxy): 14 1 15 2020-10-22 Aditya Keerthi <akeerthi@apple.com> 2 16 -
trunk/Source/WebKit/WebProcess/Automation/WebAutomationSessionProxy.js
r254329 r268867 253 253 { 254 254 for (var [node, identifier] of this._nodeToIdMap) { 255 if (!document.contains(node)) { 255 const rootNode = node.getRootNode({ composed: true }); 256 if (rootNode !== document) { 256 257 this._nodeToIdMap.delete(node); 257 258 this._idToNodeMap.delete(identifier);
Note: See TracChangeset
for help on using the changeset viewer.