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

Side by Side Diff: webkit/compositor_bindings/web_compositor_impl.cc

Issue 11186039: Move CC switches to cc/switches.h. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Switch ui/compositor back to using compositorSupport() Created 8 years, 2 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
OLDNEW
1 // Copyright 2011 The Chromium Authors. All rights reserved. 1 // Copyright 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "config.h" 5 #include "config.h"
6 6
7 #include "web_compositor_impl.h" 7 #include "web_compositor_impl.h"
8 8
9 #ifdef LOG 9 #ifdef LOG
10 #undef LOG 10 #undef LOG
(...skipping 20 matching lines...) Expand all
31 } 31 }
32 32
33 bool WebCompositor::isThreadingEnabled() 33 bool WebCompositor::isThreadingEnabled()
34 { 34 {
35 return WebCompositorImpl::isThreadingEnabled(); 35 return WebCompositorImpl::isThreadingEnabled();
36 } 36 }
37 37
38 void WebCompositor::shutdown() 38 void WebCompositor::shutdown()
39 { 39 {
40 WebCompositorImpl::shutdown(); 40 WebCompositorImpl::shutdown();
41 CCSettings::reset();
42 }
43
44 void WebCompositor::setPerTilePaintingEnabled(bool enabled)
45 {
46 ASSERT(!WebCompositorImpl::initialized());
47 CCSettings::setPerTilePaintingEnabled(enabled);
48 }
49
50 void WebCompositor::setPartialSwapEnabled(bool enabled)
51 {
52 ASSERT(!WebCompositorImpl::initialized());
53 CCSettings::setPartialSwapEnabled(enabled);
54 }
55
56 void WebCompositor::setAcceleratedAnimationEnabled(bool enabled)
57 {
58 ASSERT(!WebCompositorImpl::initialized());
59 CCSettings::setAcceleratedAnimationEnabled(enabled);
60 }
61
62 void WebCompositor::setPageScalePinchZoomEnabled(bool enabled)
63 {
64 ASSERT(!WebCompositorImpl::initialized());
65 CCSettings::setPageScalePinchZoomEnabled(enabled);
66 } 41 }
67 42
68 void WebCompositorImpl::initialize(WebThread* implThread) 43 void WebCompositorImpl::initialize(WebThread* implThread)
69 { 44 {
70 ASSERT(!s_initialized); 45 ASSERT(!s_initialized);
71 s_initialized = true; 46 s_initialized = true;
72 47
73 s_mainThread = CCThreadImpl::createForCurrentThread().release(); 48 s_mainThread = CCThreadImpl::createForCurrentThread().release();
74 CCProxy::setMainThread(s_mainThread); 49 CCProxy::setMainThread(s_mainThread);
75 if (implThread) { 50 if (implThread) {
(...skipping 23 matching lines...) Expand all
99 s_implThread = 0; 74 s_implThread = 0;
100 } 75 }
101 delete s_mainThread; 76 delete s_mainThread;
102 s_mainThread = 0; 77 s_mainThread = 0;
103 CCProxy::setImplThread(0); 78 CCProxy::setImplThread(0);
104 CCProxy::setMainThread(0); 79 CCProxy::setMainThread(0);
105 s_initialized = false; 80 s_initialized = false;
106 } 81 }
107 82
108 } 83 }
OLDNEW
« no previous file with comments | « content/renderer/render_view_impl.cc ('k') | webkit/compositor_bindings/web_compositor_support_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698