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

Unified Diff: trunk/Source/core/dom/NodeLayoutStyle.h

Issue 948053002: Revert 190605 "Make RenderObject::style() return a const object" (Closed) Base URL: svn://svn.chromium.org/blink/
Patch Set: Created 5 years, 10 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 | « trunk/Source/core/dom/Node.cpp ('k') | trunk/Source/core/dom/PseudoElement.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: trunk/Source/core/dom/NodeLayoutStyle.h
===================================================================
--- trunk/Source/core/dom/NodeLayoutStyle.h (revision 190671)
+++ trunk/Source/core/dom/NodeLayoutStyle.h (working copy)
@@ -33,10 +33,10 @@
namespace blink {
-inline LayoutStyle* Node::mutableLayoutStyle() const
+inline LayoutStyle* Node::layoutStyle() const
{
if (LayoutObject* renderer = this->renderer())
- return renderer->mutableStyle();
+ return renderer->style();
// <option> and <optgroup> can be styled even if they don't get renderers,
// so they store their style internally and return it through nonRendererStyle().
// We check here explicitly to avoid the virtual call in the common case.
@@ -45,13 +45,8 @@
return 0;
}
-inline const LayoutStyle* Node::layoutStyle() const
+inline LayoutStyle* Node::parentLayoutStyle() const
{
- return mutableLayoutStyle();
-}
-
-inline const LayoutStyle* Node::parentLayoutStyle() const
-{
ContainerNode* parent = NodeRenderingTraversal::parent(*this);
return parent ? parent->layoutStyle() : 0;
}
« no previous file with comments | « trunk/Source/core/dom/Node.cpp ('k') | trunk/Source/core/dom/PseudoElement.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698