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

Unified Diff: Source/core/css/resolver/ElementResolveContext.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
Index: Source/core/css/resolver/ElementResolveContext.cpp
diff --git a/Source/core/css/resolver/ElementResolveContext.cpp b/Source/core/css/resolver/ElementResolveContext.cpp
index b9973b3b91c8c86c82c877fe92be6000307ca221..f093d798dd2e4746db5c4fc9255caa190fa32051 100644
--- a/Source/core/css/resolver/ElementResolveContext.cpp
+++ b/Source/core/css/resolver/ElementResolveContext.cpp
@@ -31,7 +31,7 @@ namespace WebCore {
ElementResolveContext::ElementResolveContext(Element* element)
: m_element(element)
- , m_elementLinkState(element ? element->document()->visitedLinkState()->determineLinkState(element) : NotInsideLink)
+ , m_elementLinkState(element ? element->document().visitedLinkState()->determineLinkState(element) : NotInsideLink)
, m_distributedToInsertionPoint(false)
, m_resetStyleInheritance(false)
{
@@ -40,8 +40,8 @@ ElementResolveContext::ElementResolveContext(Element* element)
m_distributedToInsertionPoint = parentDetails.insertionPoint();
m_resetStyleInheritance = parentDetails.resetStyleInheritance();
- Node* documentElement = document()->documentElement();
- RenderStyle* documentStyle = document()->renderStyle();
+ Node* documentElement = document().documentElement();
+ RenderStyle* documentStyle = document().renderStyle();
m_rootElementStyle = documentElement && element != documentElement ? documentElement->renderStyle() : documentStyle;
}
« no previous file with comments | « Source/core/css/resolver/ElementResolveContext.h ('k') | Source/core/css/resolver/MatchedPropertiesCache.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698