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

Side by Side Diff: Source/core/rendering/compositing/RenderLayerCompositor.cpp

Issue 324513003: Simplify RenderLayerCompositor::rootShouldAlwaysComposite (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 6 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2009, 2010 Apple Inc. All rights reserved. 2 * Copyright (C) 2009, 2010 Apple Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 172 matching lines...) Expand 10 before | Expand all | Expand 10 after
183 183
184 bool RenderLayerCompositor::compositingLayersNeedRebuild() 184 bool RenderLayerCompositor::compositingLayersNeedRebuild()
185 { 185 {
186 // enableCompositingModeIfNeeded can set the m_compositingLayersNeedRebuild bit. 186 // enableCompositingModeIfNeeded can set the m_compositingLayersNeedRebuild bit.
187 ASSERT(!m_rootShouldAlwaysCompositeDirty); 187 ASSERT(!m_rootShouldAlwaysCompositeDirty);
188 return m_compositingLayersNeedRebuild; 188 return m_compositingLayersNeedRebuild;
189 } 189 }
190 190
191 bool RenderLayerCompositor::rootShouldAlwaysComposite() const 191 bool RenderLayerCompositor::rootShouldAlwaysComposite() const
192 { 192 {
193 if (m_hasAcceleratedCompositing && !m_renderView.frame()->isMainFrame()) 193 if (!m_hasAcceleratedCompositing)
194 return m_compositingReasonFinder.requiresCompositingForScrollableFrame() ; 194 return false;
195 return m_hasAcceleratedCompositing; 195 return m_renderView.frame()->isMainFrame() || m_compositingReasonFinder.requ iresCompositingForScrollableFrame();
196 } 196 }
197 197
198 void RenderLayerCompositor::updateAcceleratedCompositingSettings() 198 void RenderLayerCompositor::updateAcceleratedCompositingSettings()
199 { 199 {
200 m_compositingReasonFinder.updateTriggers(); 200 m_compositingReasonFinder.updateTriggers();
201 201
202 bool hasAcceleratedCompositing = m_renderView.document().settings()->acceler atedCompositingEnabled(); 202 bool hasAcceleratedCompositing = m_renderView.document().settings()->acceler atedCompositingEnabled();
203 203
204 // FIXME: Is this needed? It was added in https://bugs.webkit.org/show_bug.c gi?id=26651. 204 // FIXME: Is this needed? It was added in https://bugs.webkit.org/show_bug.c gi?id=26651.
205 // No tests fail if it's deleted. 205 // No tests fail if it's deleted.
(...skipping 1154 matching lines...) Expand 10 before | Expand all | Expand 10 after
1360 } else if (graphicsLayer == m_scrollLayer.get()) { 1360 } else if (graphicsLayer == m_scrollLayer.get()) {
1361 name = "LocalFrame Scrolling Layer"; 1361 name = "LocalFrame Scrolling Layer";
1362 } else { 1362 } else {
1363 ASSERT_NOT_REACHED(); 1363 ASSERT_NOT_REACHED();
1364 } 1364 }
1365 1365
1366 return name; 1366 return name;
1367 } 1367 }
1368 1368
1369 } // namespace WebCore 1369 } // namespace WebCore
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698