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

Side by Side Diff: Source/WebCore/rendering/RenderLayerCompositor.cpp

Issue 8506028: Merge 99485 - Source/WebCore: Create a separate setting for compositing of for scrollable [i]frames (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/912/
Patch Set: Created 9 years, 1 month 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
« no previous file with comments | « Source/WebCore/page/Settings.cpp ('k') | Source/WebCore/testing/Internals.h » ('j') | 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 125 matching lines...) Expand 10 before | Expand all | Expand 10 after
136 bool showRepaintCounter = false; 136 bool showRepaintCounter = false;
137 bool forceCompositingMode = false; 137 bool forceCompositingMode = false;
138 138
139 if (Settings* settings = m_renderView->document()->settings()) { 139 if (Settings* settings = m_renderView->document()->settings()) {
140 hasAcceleratedCompositing = settings->acceleratedCompositingEnabled(); 140 hasAcceleratedCompositing = settings->acceleratedCompositingEnabled();
141 showDebugBorders = settings->showDebugBorders(); 141 showDebugBorders = settings->showDebugBorders();
142 showRepaintCounter = settings->showRepaintCounter(); 142 showRepaintCounter = settings->showRepaintCounter();
143 forceCompositingMode = settings->forceCompositingMode() && hasAccelerate dCompositing; 143 forceCompositingMode = settings->forceCompositingMode() && hasAccelerate dCompositing;
144 144
145 if (forceCompositingMode && m_renderView->document()->ownerElement()) 145 if (forceCompositingMode && m_renderView->document()->ownerElement())
146 forceCompositingMode = requiresCompositingForScrollableFrame(); 146 forceCompositingMode = settings->acceleratedCompositingForScrollable FramesEnabled() && requiresCompositingForScrollableFrame();
147 } 147 }
148 148
149 // We allow the chrome to override the settings, in case the page is rendere d 149 // We allow the chrome to override the settings, in case the page is rendere d
150 // on a chrome that doesn't allow accelerated compositing. 150 // on a chrome that doesn't allow accelerated compositing.
151 if (hasAcceleratedCompositing) { 151 if (hasAcceleratedCompositing) {
152 Frame* frame = m_renderView->frameView()->frame(); 152 Frame* frame = m_renderView->frameView()->frame();
153 Page* page = frame ? frame->page() : 0; 153 Page* page = frame ? frame->page() : 0;
154 if (page) { 154 if (page) {
155 ChromeClient* chromeClient = page->chrome()->client(); 155 ChromeClient* chromeClient = page->chrome()->client();
156 m_compositingTriggers = chromeClient->allowedCompositingTriggers(); 156 m_compositingTriggers = chromeClient->allowedCompositingTriggers();
(...skipping 1801 matching lines...) Expand 10 before | Expand all | Expand 10 after
1958 if (!viewLayer->isComposited()) 1958 if (!viewLayer->isComposited())
1959 return; 1959 return;
1960 1960
1961 if (GraphicsLayer* rootLayer = viewLayer->backing()->graphicsLayer()) 1961 if (GraphicsLayer* rootLayer = viewLayer->backing()->graphicsLayer())
1962 rootLayer->noteDeviceOrPageScaleFactorChangedIncludingDescendants(); 1962 rootLayer->noteDeviceOrPageScaleFactorChangedIncludingDescendants();
1963 } 1963 }
1964 1964
1965 } // namespace WebCore 1965 } // namespace WebCore
1966 1966
1967 #endif // USE(ACCELERATED_COMPOSITING) 1967 #endif // USE(ACCELERATED_COMPOSITING)
OLDNEW
« no previous file with comments | « Source/WebCore/page/Settings.cpp ('k') | Source/WebCore/testing/Internals.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698