Changeset 176447 in webkit
- Timestamp:
- Nov 21, 2014 7:55:01 AM (9 years ago)
- Location:
- trunk
- Files:
-
- 2 added
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r176433 r176447 1 2014-11-21 Chris Fleizach <cfleizach@apple.com> 2 3 AX: MathML expressions are misread by VoiceOver 4 https://bugs.webkit.org/show_bug.cgi?id=138948 5 6 Reviewed by Mario Sanchez Prada. 7 8 * platform/mac/accessibility/mathml-root-expected.txt: Added. 9 * platform/mac/accessibility/mathml-root.html: Added. 10 1 11 2014-11-20 Daniel Bates <dabates@apple.com> 2 12 -
trunk/Source/WebCore/ChangeLog
r176437 r176447 1 2014-11-21 Chris Fleizach <cfleizach@apple.com> 2 3 AX: MathML expressions are misread by VoiceOver 4 https://bugs.webkit.org/show_bug.cgi?id=138948 5 6 Reviewed by Mario Sanchez Prada. 7 8 The logic for deciding what's the radicand and an index was too tied to children placement. 9 We should instead pull directly from the source. 10 11 Test: platform/mac/accessibility/mathml-root.html 12 13 * accessibility/AccessibilityRenderObject.cpp: 14 (WebCore::AccessibilityRenderObject::mathRadicandObject): 15 (WebCore::AccessibilityRenderObject::mathRootIndexObject): 16 * rendering/mathml/RenderMathMLRoot.h: 17 1 18 2014-11-20 Benjamin Poulain <bpoulain@apple.com> 2 19 -
trunk/Source/WebCore/accessibility/AccessibilityRenderObject.cpp
r176321 r176447 83 83 #include "RenderMathMLFraction.h" 84 84 #include "RenderMathMLOperator.h" 85 #include "RenderMathMLRoot.h" 85 86 #include "RenderMenuList.h" 86 87 #include "RenderSVGRoot.h" … … 3624 3625 if (!isMathRoot()) 3625 3626 return nullptr; 3626 3627 const auto& children = this->children();3628 if ( children.size() < 1)3629 return 0;3630 3631 // The radicand is the value being rooted and must be listed first.3632 return children[0].get();3627 RenderMathMLRoot* root = &downcast<RenderMathMLRoot>(*m_renderer); 3628 AccessibilityObject* rootRadicandWrapper = axObjectCache()->getOrCreate(root->baseWrapper()); 3629 if (!rootRadicandWrapper) 3630 return nullptr; 3631 AccessibilityObject* rootRadicand = rootRadicandWrapper->children().first().get(); 3632 ASSERT(rootRadicand && children().contains(rootRadicand)); 3633 return rootRadicand; 3633 3634 } 3634 3635 … … 3637 3638 if (!isMathRoot()) 3638 3639 return nullptr; 3639 3640 const auto& children = this->children(); 3641 if (children.size() != 2) 3642 return nullptr; 3643 3644 // The index in a root is the value which determines if it's a square, cube, etc, root 3645 // and must be listed second. 3646 return children[1].get(); 3640 RenderMathMLRoot* root = &downcast<RenderMathMLRoot>(*m_renderer); 3641 AccessibilityObject* rootIndexWrapper = axObjectCache()->getOrCreate(root->indexWrapper()); 3642 if (!rootIndexWrapper) 3643 return nullptr; 3644 AccessibilityObject* rootIndex = rootIndexWrapper->children().first().get(); 3645 ASSERT(rootIndex && children().contains(rootIndex)); 3646 return rootIndex; 3647 3647 } 3648 3648 -
trunk/Source/WebCore/rendering/mathml/RenderMathMLRoot.h
r175084 r176447 50 50 virtual void updateFromElement() override; 51 51 52 RenderMathMLRootWrapper* baseWrapper() const; 53 RenderMathMLRootWrapper* indexWrapper() const; 54 52 55 protected: 53 56 virtual void layout() override; … … 62 65 void restructureWrappers(); 63 66 64 RenderMathMLRootWrapper* baseWrapper() const;65 67 RenderMathMLBlock* radicalWrapper() const; 66 RenderMathMLRootWrapper* indexWrapper() const;67 68 RenderMathMLRadicalOperator* radicalOperator() const; 68 69
Note: See TracChangeset
for help on using the changeset viewer.