Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1583)

Unified Diff: Source/core/rendering/RenderWidget.cpp

Issue 23819007: Have Node::document() return a reference instead of a pointer (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase on master Created 7 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/rendering/RenderView.cpp ('k') | Source/core/rendering/RootInlineBox.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/rendering/RenderWidget.cpp
diff --git a/Source/core/rendering/RenderWidget.cpp b/Source/core/rendering/RenderWidget.cpp
index f8572e6f9b0da6d31d3a21481b4895be559763bb..a4ea8ebb60e6ebd9e73d5d9628b169a1c757add4 100644
--- a/Source/core/rendering/RenderWidget.cpp
+++ b/Source/core/rendering/RenderWidget.cpp
@@ -83,7 +83,7 @@ static void moveWidgetToParentSoon(Widget* child, FrameView* parent)
RenderWidget::RenderWidget(Element* element)
: RenderReplaced(element)
, m_widget(0)
- , m_frameView(element->document()->view())
+ , m_frameView(element->document().view())
// Reference counting is used to prevent the widget from being
// destroyed while inside the Widget code, which might not be
// able to handle that.
@@ -97,7 +97,7 @@ void RenderWidget::willBeDestroyed()
if (RenderView* v = view())
v->removeWidget(this);
- if (AXObjectCache* cache = document()->existingAXObjectCache()) {
+ if (AXObjectCache* cache = document().existingAXObjectCache()) {
cache->childrenChanged(this->parent());
cache->remove(this);
}
@@ -198,7 +198,7 @@ void RenderWidget::setWidget(PassRefPtr<Widget> widget)
moveWidgetToParentSoon(m_widget.get(), m_frameView);
}
- if (AXObjectCache* cache = document()->existingAXObjectCache())
+ if (AXObjectCache* cache = document().existingAXObjectCache())
cache->childrenChanged(this);
}
@@ -296,7 +296,7 @@ void RenderWidget::paint(PaintInfo& paintInfo, const LayoutPoint& paintOffset)
paintInfo.context->restore();
// Paint a partially transparent wash over selected widgets.
- if (isSelected() && !document()->printing()) {
+ if (isSelected() && !document().printing()) {
// FIXME: selectionRect() is in absolute, not painting coordinates.
paintInfo.context->fillRect(pixelSnappedIntRect(selectionRect()), selectionBackgroundColor());
}
« no previous file with comments | « Source/core/rendering/RenderView.cpp ('k') | Source/core/rendering/RootInlineBox.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698