Fix for accessibility/aria-grid-with-aria-owns-rows.html in isolated tree mode.
<rdar://problem/91961398>
Created attachment 457899 [details] Patch
Comment on attachment 457899 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=457899&action=review > Source/WebCore/accessibility/isolatedtree/AXIsolatedObject.cpp:52 > + initializeAttributeData(axObject, !m_parentID.isValid()); What is the second Boolean parameter here? Can we make it an enum or evaluate the property inside this method?
Comment on attachment 457899 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=457899&action=review > Source/WebCore/accessibility/isolatedtree/AXIsolatedObject.cpp:52 > + initializeAttributeData(axObject, !m_parentID.isValid()); Is it safe to use member variables inside the constructor of an object, even if we've initialized it above? > Source/WebCore/accessibility/isolatedtree/AXIsolatedTree.cpp:189 > + auto object = AXIsolatedObject::create(axObject, this); Below in this method, we update the node map with the passed-in parentID, which can be different than what AXIsolatedObject::create computes for itself with this patch. Will that be a problem?
In AXIsolatedTree, we have a member variable: HashMap<AXID, std::pair<AXID, AttachWrapper>> m_unresolvedPendingAppends; Where the first part of the pair is the parent ID that should be used to resolve the append (i.e. when we call nodeChangeForObject for the object). With your change, do we still need this data in m_unresolvedPendingAppends?
Created attachment 458060 [details] Patch
(In reply to chris fleizach from comment #3) > Comment on attachment 457899 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=457899&action=review > > > Source/WebCore/accessibility/isolatedtree/AXIsolatedObject.cpp:52 > > + initializeAttributeData(axObject, !m_parentID.isValid()); > > What is the second Boolean parameter here? Can we make it an enum or > evaluate the property inside this method? Done.
(In reply to Tyler Wilcock from comment #4) > Comment on attachment 457899 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=457899&action=review > > > Source/WebCore/accessibility/isolatedtree/AXIsolatedObject.cpp:52 > > + initializeAttributeData(axObject, !m_parentID.isValid()); > > Is it safe to use member variables inside the constructor of an object, even > if we've initialized it above? Yes. > > > Source/WebCore/accessibility/isolatedtree/AXIsolatedTree.cpp:189 > > + auto object = AXIsolatedObject::create(axObject, this); > > Below in this method, we update the node map with the passed-in parentID, > which can be different than what AXIsolatedObject::create computes for > itself with this patch. Will that be a problem? Fixed, thanks for pointing it out. Cleaned up the whole thing of passing the parentIDs.
(In reply to Tyler Wilcock from comment #5) > In AXIsolatedTree, we have a member variable: > > HashMap<AXID, std::pair<AXID, AttachWrapper>> m_unresolvedPendingAppends; > > Where the first part of the pair is the parent ID that should be used to > resolve the append (i.e. when we call nodeChangeForObject for the object). > > With your change, do we still need this data in m_unresolvedPendingAppends? No we don't need that any more, so I cleaned it up. Thanks for pointing that out.
Committed r293219 (249888@main): <https://commits.webkit.org/249888@main> All reviewed patches have been landed. Closing bug and clearing flags on attachment 458060 [details].