Index: Source/core/html/canvas/HitRegion.cpp |
diff --git a/Source/core/html/canvas/HitRegion.cpp b/Source/core/html/canvas/HitRegion.cpp |
index c1e2aa96aa9afd610d87025cd78ded94e761696e..1384001e291f8c850b4704d1418b4725bfce8137 100644 |
--- a/Source/core/html/canvas/HitRegion.cpp |
+++ b/Source/core/html/canvas/HitRegion.cpp |
@@ -23,7 +23,7 @@ HitRegion::HitRegion(const Path& path, const HitRegionOptions& options) |
void HitRegion::updateAccessibility(Element* canvas) |
{ |
- if (!m_control || !canvas || !canvas->renderer() || !m_control->isDescendantOf(canvas)) |
+ if (!m_control || !canvas || !canvas->layoutObject() || !m_control->isDescendantOf(canvas)) |
return; |
AXObjectCache* axObjectCache = m_control->document().existingAXObjectCache(); |
@@ -34,7 +34,7 @@ void HitRegion::updateAccessibility(Element* canvas) |
// Offset by the canvas rect, taking border and padding into account. |
LayoutBoxModelObject* rbmo = canvas->layoutBoxModelObject(); |
- IntRect canvasRect = canvas->renderer()->absoluteBoundingBoxRect(); |
+ IntRect canvasRect = canvas->layoutObject()->absoluteBoundingBoxRect(); |
canvasRect.move(rbmo->borderLeft() + rbmo->paddingLeft(), |
rbmo->borderTop() + rbmo->paddingTop()); |
LayoutRect elementRect = enclosingLayoutRect(boundingRect); |