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

Side by Side Diff: content/renderer/scheduler/renderer_scheduler.cc

Issue 711393002: Revert "content: Enable the RendererScheduler by default." (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 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 | « 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 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "content/renderer/scheduler/renderer_scheduler.h" 5 #include "content/renderer/scheduler/renderer_scheduler.h"
6 6
7 #include "base/command_line.h"
8 #include "base/message_loop/message_loop_proxy.h"
9 #include "content/public/common/content_switches.h"
10 #include "content/renderer/scheduler/null_renderer_scheduler.h" 7 #include "content/renderer/scheduler/null_renderer_scheduler.h"
11 #include "content/renderer/scheduler/renderer_scheduler_impl.h"
12 8
13 namespace content { 9 namespace content {
14 10
15 RendererScheduler::RendererScheduler() { 11 RendererScheduler::RendererScheduler() {
16 } 12 }
17 13
18 RendererScheduler::~RendererScheduler() { 14 RendererScheduler::~RendererScheduler() {
19 } 15 }
20 16
21 // static 17 // static
22 scoped_ptr<RendererScheduler> RendererScheduler::Create() { 18 scoped_ptr<RendererScheduler> RendererScheduler::Create() {
23 CommandLine* command_line = base::CommandLine::ForCurrentProcess(); 19 // TODO(rmcilroy): Use the RendererSchedulerImpl when the scheduler is enabled
24 if (command_line->HasSwitch(switches::kDisableBlinkScheduler)) { 20 return make_scoped_ptr(new NullRendererScheduler());
25 return make_scoped_ptr(new NullRendererScheduler());
26 } else {
27 return make_scoped_ptr(
28 new RendererSchedulerImpl(base::MessageLoopProxy::current()));
29 }
30 } 21 }
31 22
32 } // namespace content 23 } // namespace content
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