WebKit Bugzilla
Attachment 358858 Details for
Bug 193225
: Web Inspector: Audit: provide a way to get related Accessibility nodes for a given node
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
193225.diff (text/plain), 21.75 KB, created by
Devin Rousso
on 2019-01-10 18:55:02 PST
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Devin Rousso
Created:
2019-01-10 18:55:02 PST
Size:
21.75 KB
patch
obsolete
>diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog >index 0b015d8fb20..036e2e89f06 100644 >--- a/LayoutTests/ChangeLog >+++ b/LayoutTests/ChangeLog >@@ -1,3 +1,14 @@ >+2019-01-10 Devin Rousso <drousso@apple.com> >+ >+ Web Inspector: Audit: provide a way to get related Accessibility nodes for a given node >+ https://bugs.webkit.org/show_bug.cgi?id=193225 >+ <rdar://problem/46799956> >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * inspector/audit/run-accessibility.html: Added. >+ * inspector/audit/run-accessibility-expected.txt: Added. >+ > 2019-01-06 Devin Rousso <drousso@apple.com> > > Web Inspector: Audit: create new IDL type for exposing special functionality in test context >diff --git a/LayoutTests/inspector/audit/run-accessibility-expected.txt b/LayoutTests/inspector/audit/run-accessibility-expected.txt >new file mode 100644 >index 00000000000..ff14424fb6b >--- /dev/null >+++ b/LayoutTests/inspector/audit/run-accessibility-expected.txt >@@ -0,0 +1,129 @@ >+Tests for the injected AUDIT.Accessibility functions. >+ >+ >+== Running test suite: Audit.run.Accessibility >+-- Running test case: Audit.run.Accessibility.getActiveDescendant.parent >+Audit setup... >+Audit run `AUDIT.Accessibility.getActiveDescendant(document.querySelector("#parent"))`... >+Result: #child >+Audit teardown... >+ >+-- Running test case: Audit.run.Accessibility.getActiveDescendant.child >+Audit setup... >+Audit run `AUDIT.Accessibility.getActiveDescendant(document.querySelector("#child"))`... >+Result: null >+Audit teardown... >+ >+-- Running test case: Audit.run.Accessibility.getChildNodes.parent >+Audit setup... >+Audit run `AUDIT.Accessibility.getChildNodes(document.querySelector("#parent"))`... >+Result: ["#child"] >+Audit teardown... >+ >+-- Running test case: Audit.run.Accessibility.getChildNodes.child >+Audit setup... >+Audit run `AUDIT.Accessibility.getChildNodes(document.querySelector("#child"))`... >+Result: [] >+Audit teardown... >+ >+-- Running test case: Audit.run.Accessibility.getControlledNodes.parent >+Audit setup... >+Audit run `AUDIT.Accessibility.getControlledNodes(document.querySelector("#parent"))`... >+Result: ["#child"] >+Audit teardown... >+ >+-- Running test case: Audit.run.Accessibility.getControlledNodes.child >+Audit setup... >+Audit run `AUDIT.Accessibility.getControlledNodes(document.querySelector("#child"))`... >+Result: [] >+Audit teardown... >+ >+-- Running test case: Audit.run.Accessibility.getFlowedNodes.parent >+Audit setup... >+Audit run `AUDIT.Accessibility.getFlowedNodes(document.querySelector("#parent"))`... >+Result: ["#child"] >+Audit teardown... >+ >+-- Running test case: Audit.run.Accessibility.getFlowedNodes.child >+Audit setup... >+Audit run `AUDIT.Accessibility.getFlowedNodes(document.querySelector("#child"))`... >+Result: [] >+Audit teardown... >+ >+-- Running test case: Audit.run.Accessibility.getMouseEventNode.parent >+Audit setup... >+Audit run `AUDIT.Accessibility.getMouseEventNode(document.querySelector("#parent"))`... >+Result: #parent >+Audit teardown... >+ >+-- Running test case: Audit.run.Accessibility.getMouseEventNode.child >+Audit setup... >+Audit run `AUDIT.Accessibility.getMouseEventNode(document.querySelector("#child"))`... >+Result: #parent >+Audit teardown... >+ >+-- Running test case: Audit.run.Accessibility.getOwnedNodes.parent >+Audit setup... >+Audit run `AUDIT.Accessibility.getOwnedNodes(document.querySelector("#parent"))`... >+Result: ["#child"] >+Audit teardown... >+ >+-- Running test case: Audit.run.Accessibility.getOwnedNodes.child >+Audit setup... >+Audit run `AUDIT.Accessibility.getOwnedNodes(document.querySelector("#child"))`... >+Result: null >+Audit teardown... >+ >+-- Running test case: Audit.run.Accessibility.getParentNode.parent >+Audit setup... >+Audit run `AUDIT.Accessibility.getParentNode(document.querySelector("#parent"))`... >+Result: null >+Audit teardown... >+ >+-- Running test case: Audit.run.Accessibility.getParentNode.child >+Audit setup... >+Audit run `AUDIT.Accessibility.getParentNode(document.querySelector("#child"))`... >+Result: #parent >+Audit teardown... >+ >+-- Running test case: Audit.run.Accessibility.getSelectedChildNodes.parent >+Audit setup... >+Audit run `AUDIT.Accessibility.getSelectedChildNodes(document.querySelector("#parent"))`... >+Result: ["#child"] >+Audit teardown... >+ >+-- Running test case: Audit.run.Accessibility.getSelectedChildNodes.child >+Audit setup... >+Audit run `AUDIT.Accessibility.getSelectedChildNodes(document.querySelector("#child"))`... >+Result: [] >+Audit teardown... >+ >+-- Running test case: Audit.run.Accessibility.InvalidCopiedFunctionCall >+Audit setup... >+Copying AUDIT to window... >+Audit teardown... >+Testing copied getActiveDescendant... >+PASS: Should produce an exception. >+Error: NotAllowedError: Unable to run outside of an Inspector Audit >+Testing copied getChildNodes... >+PASS: Should produce an exception. >+Error: NotAllowedError: Unable to run outside of an Inspector Audit >+Testing copied getControlledNodes... >+PASS: Should produce an exception. >+Error: NotAllowedError: Unable to run outside of an Inspector Audit >+Testing copied getFlowedNodes... >+PASS: Should produce an exception. >+Error: NotAllowedError: Unable to run outside of an Inspector Audit >+Testing copied getMouseEventNode... >+PASS: Should produce an exception. >+Error: NotAllowedError: Unable to run outside of an Inspector Audit >+Testing copied getOwnedNodes... >+PASS: Should produce an exception. >+Error: NotAllowedError: Unable to run outside of an Inspector Audit >+Testing copied getParentNode... >+PASS: Should produce an exception. >+Error: NotAllowedError: Unable to run outside of an Inspector Audit >+Testing copied getSelectedChildNodes... >+PASS: Should produce an exception. >+Error: NotAllowedError: Unable to run outside of an Inspector Audit >+ >diff --git a/LayoutTests/inspector/audit/run-accessibility.html b/LayoutTests/inspector/audit/run-accessibility.html >new file mode 100644 >index 00000000000..e777e455242 >--- /dev/null >+++ b/LayoutTests/inspector/audit/run-accessibility.html >@@ -0,0 +1,97 @@ >+<!DOCTYPE html> >+<html> >+<head> >+<script src="../../http/tests/inspector/resources/inspector-test.js"></script> >+<script src="resources/audit-utilities.js"></script> >+<script> >+ >+function stringify(result) { >+ if (result instanceof Element) >+ return "#" + result.id; >+ if (Array.isArray(result)) >+ return JSON.stringify(result.map(stringify)); >+ return null; >+} >+ >+function test() >+{ >+ let suite = InspectorTest.Audit.createSuite("Audit.run.Accessibility"); >+ >+ function evaluateStringForTest(func, target) { >+ return `Accessibility.${func}(document.querySelector("#${target}"))`; >+ } >+ >+ const tests = [ >+ { func: "getActiveDescendant", target: "parent" }, >+ { func: "getActiveDescendant", target: "child" }, >+ { func: "getChildNodes", target: "parent" }, >+ { func: "getChildNodes", target: "child" }, >+ { func: "getControlledNodes", target: "parent" }, >+ { func: "getControlledNodes", target: "child" }, >+ { func: "getFlowedNodes", target: "parent" }, >+ { func: "getFlowedNodes", target: "child" }, >+ { func: "getMouseEventNode", target: "parent" }, >+ { func: "getMouseEventNode", target: "child" }, >+ { func: "getOwnedNodes", target: "parent" }, >+ { func: "getOwnedNodes", target: "child" }, >+ { func: "getParentNode", target: "parent" }, >+ { func: "getParentNode", target: "child" }, >+ { func: "getSelectedChildNodes", target: "parent" }, >+ { func: "getSelectedChildNodes", target: "child" }, >+ ]; >+ >+ for (let {func, target} of tests) { >+ suite.addTestCase({ >+ name: "Audit.run.Accessibility." + func + "." + target, >+ async test() { >+ let functionString = "AUDIT." + evaluateStringForTest(func, target); >+ >+ await InspectorTest.Audit.setupAudit(); >+ >+ InspectorTest.log(`Audit run \`${functionString}\`...`); >+ let {result, wasThrown} = await AuditAgent.run(`function() { return stringify(${functionString}); }`); >+ InspectorTest.assert(!wasThrown, "Should not throw an exception."); >+ if (!wasThrown) >+ InspectorTest.log("Result: " + result.value); >+ else >+ InspectorTest.log(result.description); >+ >+ await InspectorTest.Audit.teardownAudit(); >+ }, >+ }); >+ } >+ >+ suite.addTestCase({ >+ name: "Audit.run.Accessibility.InvalidCopiedFunctionCall", >+ description: "Check that AUDIT.Accessibility functions throw an error when called outside of an audit.", >+ async test() { >+ let functions = new Map; >+ for (let test of tests) >+ functions.set(test.func, test); >+ >+ await InspectorTest.Audit.setupAudit(); >+ InspectorTest.log(`Copying AUDIT to window...`); >+ let {wasThrown} = await AuditAgent.run(`function() { window.AUDITCopy = AUDIT; }`); >+ InspectorTest.assert(!wasThrown, "Should not throw an exception."); >+ await InspectorTest.Audit.teardownAudit(); >+ >+ for (let {func, target} of functions.values()) { >+ InspectorTest.log(`Testing copied ${func}...`); >+ await InspectorTest.expectException(async function() { >+ await InspectorTest.evaluateInPage("window.AUDITCopy." + evaluateStringForTest(func, target)); >+ }); >+ } >+ }, >+ }); >+ >+ suite.runTestCasesAndFinish(); >+} >+</script> >+</head> >+<body onload="runTest()"> >+ <p>Tests for the injected AUDIT.Accessibility functions.</p> >+ <ul id="parent" role="tree" aria-activedescendant="child" aria-controls="child" aria-flowto="child" aria-owns="child" onclick="void(0);"> >+ <li id="child" role="treeitem" aria-selected="true"></li> >+ </ul> >+</body> >+</html> >diff --git a/Source/WebCore/ChangeLog b/Source/WebCore/ChangeLog >index c05068dc003..7ed38e650a6 100644 >--- a/Source/WebCore/ChangeLog >+++ b/Source/WebCore/ChangeLog >@@ -1,3 +1,27 @@ >+2019-01-10 Devin Rousso <drousso@apple.com> >+ >+ Web Inspector: Audit: provide a way to get related Accessibility nodes for a given node >+ https://bugs.webkit.org/show_bug.cgi?id=193225 >+ <rdar://problem/46799956> >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ Test: inspector/audit/run-accessibility.html >+ >+ * inspector/InspectorAuditAccessibilityUtilities.idl: >+ * inspector/InspectorAuditAccessibilityUtilities.h: >+ * inspector/InspectorAuditAccessibilityUtilities.cpp: >+ (WebCore::accessiblityObjectForNode): Added. >+ (WebCore::InspectorAuditAccessibilityUtilities::getActiveDescendant): Added. >+ (WebCore::addChildren): Added. >+ (WebCore::InspectorAuditAccessibilityUtilities::getChildNodes): Added. >+ (WebCore::InspectorAuditAccessibilityUtilities::getControlledNodes): Added. >+ (WebCore::InspectorAuditAccessibilityUtilities::getFlowedNodes): Added. >+ (WebCore::InspectorAuditAccessibilityUtilities::getMouseEventNode): Added. >+ (WebCore::InspectorAuditAccessibilityUtilities::getOwnedNodes): Added. >+ (WebCore::InspectorAuditAccessibilityUtilities::getParentNode): Added. >+ (WebCore::InspectorAuditAccessibilityUtilities::getSelectedChildNodes): Added. >+ > 2019-01-10 Devin Rousso <drousso@apple.com> > > Web Inspector: Audit: create new IDL type for exposing special functionality in test context >diff --git a/Source/WebCore/inspector/InspectorAuditAccessibilityUtilities.cpp b/Source/WebCore/inspector/InspectorAuditAccessibilityUtilities.cpp >index 3c84fc3b9ca..62d339f8eff 100644 >--- a/Source/WebCore/inspector/InspectorAuditAccessibilityUtilities.cpp >+++ b/Source/WebCore/inspector/InspectorAuditAccessibilityUtilities.cpp >@@ -27,12 +27,182 @@ > #include "config.h" > #include "InspectorAuditAccessibilityUtilities.h" > >+#include "AXObjectCache.h" >+#include "AccessibilityNodeObject.h" >+#include "AccessibilityObject.h" >+#include "Document.h" >+#include "Element.h" >+#include "HTMLNames.h" >+#include "Node.h" >+#include <wtf/Vector.h> >+ > namespace WebCore { > > using namespace Inspector; > >-InspectorAuditAccessibilityUtilities::InspectorAuditAccessibilityUtilities() >+#define ERROR_IF_NO_ACTIVE_AUDIT() if (!m_auditAgent.hasActiveAudit()) return Exception { NotAllowedError, "Unable to run outside of an Inspector Audit"_s }; >+ >+InspectorAuditAccessibilityUtilities::InspectorAuditAccessibilityUtilities(InspectorAuditAgent& auditAgent) >+ : m_auditAgent(auditAgent) > { > } > >+static AccessibilityObject* accessiblityObjectForNode(Node& node) >+{ >+ if (!AXObjectCache::accessibilityEnabled()) >+ AXObjectCache::enableAccessibility(); >+ >+ if (AXObjectCache* axObjectCache = node.document().axObjectCache()) >+ return axObjectCache->getOrCreate(&node); >+ return nullptr; >+} >+ >+ExceptionOr<RefPtr<Node>> InspectorAuditAccessibilityUtilities::getActiveDescendant(Node& node) >+{ >+ ERROR_IF_NO_ACTIVE_AUDIT(); >+ >+ if (AccessibilityObject* axObject = accessiblityObjectForNode(node)) { >+ if (AccessibilityObject* activeDescendant = axObject->activeDescendant()) >+ return activeDescendant->node(); >+ } >+ return nullptr; >+} >+ >+static void addChildren(AccessibilityObject& parentObject, Vector<RefPtr<Node>>& childNodes) >+{ >+ for (const RefPtr<AccessibilityObject>& childObject : parentObject.children()) { >+ if (Node* childNode = childObject->node()) >+ childNodes.append(childNode); >+ else >+ addChildren(*childObject, childNodes); >+ } >+} >+ >+ExceptionOr<Optional<Vector<RefPtr<Node>>>> InspectorAuditAccessibilityUtilities::getChildNodes(Node& node) >+{ >+ ERROR_IF_NO_ACTIVE_AUDIT(); >+ >+ Optional<Vector<RefPtr<Node>>> result; >+ >+ if (AccessibilityObject* axObject = accessiblityObjectForNode(node)) { >+ Vector<RefPtr<Node>> childNodes; >+ addChildren(*axObject, childNodes); >+ result = WTFMove(childNodes); >+ } >+ >+ return result; >+} >+ >+ >+ExceptionOr<Optional<Vector<RefPtr<Node>>>> InspectorAuditAccessibilityUtilities::getControlledNodes(Node& node) >+{ >+ ERROR_IF_NO_ACTIVE_AUDIT(); >+ >+ Optional<Vector<RefPtr<Node>>> result; >+ >+ if (AccessibilityObject* axObject = accessiblityObjectForNode(node)) { >+ Vector<RefPtr<Node>> controlledNodes; >+ >+ Vector<Element*> controlledElements; >+ axObject->elementsFromAttribute(controlledElements, HTMLNames::aria_controlsAttr); >+ for (Element* controlledElement : controlledElements) { >+ if (controlledElement) >+ controlledNodes.append(controlledElement); >+ } >+ >+ result = WTFMove(controlledNodes); >+ } >+ >+ return result; >+} >+ >+ExceptionOr<Optional<Vector<RefPtr<Node>>>> InspectorAuditAccessibilityUtilities::getFlowedNodes(Node& node) >+{ >+ ERROR_IF_NO_ACTIVE_AUDIT(); >+ >+ Optional<Vector<RefPtr<Node>>> result; >+ >+ if (AccessibilityObject* axObject = accessiblityObjectForNode(node)) { >+ Vector<RefPtr<Node>> flowedNodes; >+ >+ Vector<Element*> flowedElements; >+ axObject->elementsFromAttribute(flowedElements, HTMLNames::aria_flowtoAttr); >+ for (Element* flowedElement : flowedElements) { >+ if (flowedElement) >+ flowedNodes.append(flowedElement); >+ } >+ >+ result = WTFMove(flowedNodes); >+ } >+ return result; >+} >+ >+ExceptionOr<RefPtr<Node>> InspectorAuditAccessibilityUtilities::getMouseEventNode(Node& node) >+{ >+ ERROR_IF_NO_ACTIVE_AUDIT(); >+ >+ if (AccessibilityObject* axObject = accessiblityObjectForNode(node)) { >+ if (is<AccessibilityNodeObject>(axObject)) >+ return downcast<AccessibilityNodeObject>(axObject)->mouseButtonListener(MouseButtonListenerResultFilter::IncludeBodyElement); >+ } >+ return nullptr; >+} >+ >+ExceptionOr<Optional<Vector<RefPtr<Node>>>> InspectorAuditAccessibilityUtilities::getOwnedNodes(Node& node) >+{ >+ ERROR_IF_NO_ACTIVE_AUDIT(); >+ >+ Optional<Vector<RefPtr<Node>>> result; >+ >+ if (AccessibilityObject* axObject = accessiblityObjectForNode(node)) { >+ if (axObject->supportsARIAOwns()) { >+ Vector<RefPtr<Node>> ownedNodes; >+ >+ Vector<Element*> ownedElements; >+ axObject->elementsFromAttribute(ownedElements, HTMLNames::aria_ownsAttr); >+ for (Element* ownedElement : ownedElements) { >+ if (ownedElement) >+ ownedNodes.append(ownedElement); >+ } >+ >+ result = WTFMove(ownedNodes); >+ } >+ } >+ >+ return result; >+} >+ >+ExceptionOr<RefPtr<Node>> InspectorAuditAccessibilityUtilities::getParentNode(Node& node) >+{ >+ ERROR_IF_NO_ACTIVE_AUDIT(); >+ >+ if (AccessibilityObject* axObject = accessiblityObjectForNode(node)) { >+ if (AccessibilityObject* parentObject = axObject->parentObjectUnignored()) >+ return parentObject->node(); >+ } >+ return nullptr; >+} >+ >+ExceptionOr<Optional<Vector<RefPtr<Node>>>> InspectorAuditAccessibilityUtilities::getSelectedChildNodes(Node& node) >+{ >+ ERROR_IF_NO_ACTIVE_AUDIT(); >+ >+ Optional<Vector<RefPtr<Node>>> result; >+ >+ if (AccessibilityObject* axObject = accessiblityObjectForNode(node)) { >+ Vector<RefPtr<Node>> selectedChildNodes; >+ >+ AccessibilityObject::AccessibilityChildrenVector selectedChildren; >+ axObject->selectedChildren(selectedChildren); >+ for (RefPtr<AccessibilityObject>& selectedChildObject : selectedChildren) { >+ if (Node* selectedChildNode = selectedChildObject->node()) >+ selectedChildNodes.append(selectedChildNode); >+ } >+ >+ result = WTFMove(selectedChildNodes); >+ } >+ >+ return result; >+} >+ > } // namespace WebCore >diff --git a/Source/WebCore/inspector/InspectorAuditAccessibilityUtilities.h b/Source/WebCore/inspector/InspectorAuditAccessibilityUtilities.h >index 37c67bb1f25..1579b3a5be9 100644 >--- a/Source/WebCore/inspector/InspectorAuditAccessibilityUtilities.h >+++ b/Source/WebCore/inspector/InspectorAuditAccessibilityUtilities.h >@@ -25,20 +25,37 @@ > > #pragma once > >+#include "ExceptionOr.h" >+#include <JavaScriptCore/InspectorAuditAgent.h> >+#include <wtf/Forward.h> >+#include <wtf/Optional.h> > #include <wtf/Ref.h> > #include <wtf/RefCounted.h> > > namespace WebCore { > >+class Node; >+ > class InspectorAuditAccessibilityUtilities : public RefCounted<InspectorAuditAccessibilityUtilities> { > public: >- static Ref<InspectorAuditAccessibilityUtilities> create() >+ static Ref<InspectorAuditAccessibilityUtilities> create(Inspector::InspectorAuditAgent& auditAgent) > { >- return adoptRef(*new InspectorAuditAccessibilityUtilities()); >+ return adoptRef(*new InspectorAuditAccessibilityUtilities(auditAgent)); > } > >+ ExceptionOr<RefPtr<Node>> getActiveDescendant(Node&); >+ ExceptionOr<Optional<Vector<RefPtr<Node>>>> getChildNodes(Node&); >+ ExceptionOr<Optional<Vector<RefPtr<Node>>>> getControlledNodes(Node&); >+ ExceptionOr<Optional<Vector<RefPtr<Node>>>> getFlowedNodes(Node&); >+ ExceptionOr<RefPtr<Node>> getMouseEventNode(Node&); >+ ExceptionOr<Optional<Vector<RefPtr<Node>>>> getOwnedNodes(Node&); >+ ExceptionOr<RefPtr<Node>> getParentNode(Node&); >+ ExceptionOr<Optional<Vector<RefPtr<Node>>>> getSelectedChildNodes(Node&); >+ > private: >- explicit InspectorAuditAccessibilityUtilities(); >+ explicit InspectorAuditAccessibilityUtilities(Inspector::InspectorAuditAgent&); >+ >+ Inspector::InspectorAuditAgent& m_auditAgent; > }; > > } // namespace WebCore >diff --git a/Source/WebCore/inspector/InspectorAuditAccessibilityUtilities.idl b/Source/WebCore/inspector/InspectorAuditAccessibilityUtilities.idl >index 7ccd72bb093..ce86becedd8 100644 >--- a/Source/WebCore/inspector/InspectorAuditAccessibilityUtilities.idl >+++ b/Source/WebCore/inspector/InspectorAuditAccessibilityUtilities.idl >@@ -28,4 +28,12 @@ > JSGenerateToJSObject, > NoInterfaceObject, > ] interface InspectorAuditAccessibilityUtilities { >+ [MayThrowException] Node? getActiveDescendant(Node node); >+ [MayThrowException] sequence<Node>? getChildNodes(Node node); >+ [MayThrowException] sequence<Node>? getControlledNodes(Node node); >+ [MayThrowException] sequence<Node>? getFlowedNodes(Node node); >+ [MayThrowException] Node? getMouseEventNode(Node node); >+ [MayThrowException] sequence<Node>? getOwnedNodes(Node node); >+ [MayThrowException] Node? getParentNode(Node node); >+ [MayThrowException] sequence<Node>? getSelectedChildNodes(Node node); > }; >diff --git a/Source/WebCore/inspector/InspectorAuditDOMUtilities.h b/Source/WebCore/inspector/InspectorAuditDOMUtilities.h >index 3a4af637eff..b1feb3a0be2 100644 >--- a/Source/WebCore/inspector/InspectorAuditDOMUtilities.h >+++ b/Source/WebCore/inspector/InspectorAuditDOMUtilities.h >@@ -25,6 +25,7 @@ > > #pragma once > >+#include <JavaScriptCore/InspectorAuditAgent.h> > #include <wtf/Ref.h> > #include <wtf/RefCounted.h> > >@@ -32,7 +33,7 @@ namespace WebCore { > > class InspectorAuditDOMUtilities : public RefCounted<InspectorAuditDOMUtilities> { > public: >- static Ref<InspectorAuditDOMUtilities> create() >+ static Ref<InspectorAuditDOMUtilities> create(Inspector::InspectorAuditAgent&) > { > return adoptRef(*new InspectorAuditDOMUtilities()); > } >diff --git a/Source/WebCore/inspector/agents/page/PageAuditAgent.cpp b/Source/WebCore/inspector/agents/page/PageAuditAgent.cpp >index dbe1d36f287..e13ba14258c 100644 >--- a/Source/WebCore/inspector/agents/page/PageAuditAgent.cpp >+++ b/Source/WebCore/inspector/agents/page/PageAuditAgent.cpp >@@ -82,7 +82,7 @@ Vector<std::pair<String, JSC::JSValue>> PageAuditAgent::runArguments(const int* > > #define ADD_AUDIT_UTILITIES(name) \ > if (!m_audit##name##Utilities) \ >- m_audit##name##Utilities = InspectorAudit##name##Utilities::create(); \ >+ m_audit##name##Utilities = InspectorAudit##name##Utilities::create(*this); \ > if (JSC::JSValue inspectorAudit##name##Utilities = toJS(execState, globalObject, *m_audit##name##Utilities)) \ > arguments.append(std::make_pair("" #name ""_s, WTFMove(inspectorAudit##name##Utilities))); >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 193225
:
358565
|
358568
|
358848
|
358858
|
359174
|
359175
|
359182
|
359183
|
359188
|
359232
|
359237
|
359240
|
359244
|
359562
|
359567
|
359572
|
359581
|
359596
|
359601
|
359602
|
359604
|
359749