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

Unified Diff: ui/compositor/compositor.cc

Issue 10918161: Use WebCompositorSupport for ui/compositor initialization and shutdown (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 3 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/compositor/compositor.cc
diff --git a/ui/compositor/compositor.cc b/ui/compositor/compositor.cc
index 3bc4b7cd213207720d93ed0cdd7196546bfa7dd5..9a0030263ef3059b63154d53c42b9e21a8932a64 100644
--- a/ui/compositor/compositor.cc
+++ b/ui/compositor/compositor.cc
@@ -15,7 +15,6 @@
#include "third_party/WebKit/Source/Platform/chromium/public/WebFloatPoint.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebRect.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebSize.h"
-#include "third_party/WebKit/Source/Platform/chromium/public/WebCompositor.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebCompositorOutputSurface.h"
#include "ui/compositor/compositor_observer.h"
#include "ui/compositor/compositor_switches.h"
@@ -179,18 +178,20 @@ Compositor::~Compositor() {
void Compositor::Initialize(bool use_thread) {
CommandLine* command_line = CommandLine::ForCurrentProcess();
+ WebKit::WebCompositorSupport* compositor_support =
+ WebKit::Platform::current()->compositorSupport();
// These settings must be applied before we initialize the compositor.
- WebKit::WebCompositor::setPartialSwapEnabled(
+ compositor_support->setPartialSwapEnabled(
command_line->HasSwitch(switches::kUIEnablePartialSwap));
- WebKit::WebCompositor::setPerTilePaintingEnabled(
+ compositor_support->setPerTilePaintingEnabled(
command_line->HasSwitch(switches::kUIEnablePerTilePainting));
if (use_thread)
g_compositor_thread = new webkit_glue::WebThreadImpl("Browser Compositor");
- WebKit::WebCompositor::initialize(g_compositor_thread);
+ compositor_support->initialize(g_compositor_thread);
}
void Compositor::Terminate() {
- WebKit::WebCompositor::shutdown();
+ WebKit::Platform::current()->compositorSupport()->shutdown();
if (g_compositor_thread) {
delete g_compositor_thread;
g_compositor_thread = NULL;
« 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