Chromium Code Reviews

Side by Side Diff: Source/core/rendering/RenderWidget.cpp

Issue 24921002: Make compositingState explicit (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Addressed second round of reviewer feedback Created 7 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View unified diff | | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * Copyright (C) 2000 Dirk Mueller (mueller@kde.org) 3 * Copyright (C) 2000 Dirk Mueller (mueller@kde.org)
4 * Copyright (C) 2004, 2006, 2009, 2010 Apple Inc. All rights reserved. 4 * Copyright (C) 2004, 2006, 2009, 2010 Apple Inc. All rights reserved.
5 * Copyright (C) 2013 Google Inc. All rights reserved. 5 * Copyright (C) 2013 Google Inc. All rights reserved.
6 * 6 *
7 * This library is free software; you can redistribute it and/or 7 * This library is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU Library General Public 8 * modify it under the terms of the GNU Library General Public
9 * License as published by the Free Software Foundation; either 9 * License as published by the Free Software Foundation; either
10 * version 2 of the License, or (at your option) any later version. 10 * version 2 of the License, or (at your option) any later version.
(...skipping 137 matching lines...)
148 148
149 m_clipRect = clipRect; 149 m_clipRect = clipRect;
150 150
151 RefPtr<RenderWidget> protector(this); 151 RefPtr<RenderWidget> protector(this);
152 RefPtr<Node> protectedNode(node()); 152 RefPtr<Node> protectedNode(node());
153 m_widget->setFrameRect(newFrame); 153 m_widget->setFrameRect(newFrame);
154 154
155 if (clipChanged && !frameRectChanged) 155 if (clipChanged && !frameRectChanged)
156 m_widget->clipRectChanged(); 156 m_widget->clipRectChanged();
157 157
158 if (hasLayer() && layer()->isComposited()) 158 if (hasLayer() && layer()->compositingState() == PaintsIntoOwnBacking)
159 layer()->compositedLayerMapping()->updateAfterWidgetResize(); 159 layer()->compositedLayerMapping()->updateAfterWidgetResize();
160 160
161 bool boundsChanged = m_widget->frameRect().size() != newFrame.size(); 161 bool boundsChanged = m_widget->frameRect().size() != newFrame.size();
162 return boundsChanged; 162 return boundsChanged;
163 } 163 }
164 164
165 bool RenderWidget::updateWidgetGeometry() 165 bool RenderWidget::updateWidgetGeometry()
166 { 166 {
167 LayoutRect contentBox = contentBoxRect(); 167 LayoutRect contentBox = contentBoxRect();
168 LayoutRect absoluteContentBox(localToAbsoluteQuad(FloatQuad(contentBox)).bou ndingBox()); 168 LayoutRect absoluteContentBox(localToAbsoluteQuad(FloatQuad(contentBox)).bou ndingBox());
(...skipping 204 matching lines...)
373 CursorDirective RenderWidget::getCursor(const LayoutPoint& point, Cursor& cursor ) const 373 CursorDirective RenderWidget::getCursor(const LayoutPoint& point, Cursor& cursor ) const
374 { 374 {
375 if (widget() && widget()->isPluginView()) { 375 if (widget() && widget()->isPluginView()) {
376 // A plug-in is responsible for setting the cursor when the pointer is o ver it. 376 // A plug-in is responsible for setting the cursor when the pointer is o ver it.
377 return DoNotSetCursor; 377 return DoNotSetCursor;
378 } 378 }
379 return RenderReplaced::getCursor(point, cursor); 379 return RenderReplaced::getCursor(point, cursor);
380 } 380 }
381 381
382 } // namespace WebCore 382 } // namespace WebCore
OLDNEW

Powered by Google App Engine