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

Side by Side Diff: content/renderer/render_thread_impl.cc

Issue 337783002: Remove EnableThreadedCompositing from the browser. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: thread: rebase Created 6 years, 5 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/render_thread_impl.h" 5 #include "content/renderer/render_thread_impl.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <limits> 8 #include <limits>
9 #include <map> 9 #include <map>
10 #include <vector> 10 #include <vector>
(...skipping 800 matching lines...) Expand 10 before | Expand all | Expand 10 after
811 blink::initialize(webkit_platform_support_.get()); 811 blink::initialize(webkit_platform_support_.get());
812 812
813 v8::Isolate* isolate = blink::mainThreadIsolate(); 813 v8::Isolate* isolate = blink::mainThreadIsolate();
814 814
815 isolate->SetCounterFunction(base::StatsTable::FindLocation); 815 isolate->SetCounterFunction(base::StatsTable::FindLocation);
816 isolate->SetCreateHistogramFunction(CreateHistogram); 816 isolate->SetCreateHistogramFunction(CreateHistogram);
817 isolate->SetAddHistogramSampleFunction(AddHistogramSample); 817 isolate->SetAddHistogramSampleFunction(AddHistogramSample);
818 818
819 const CommandLine& command_line = *CommandLine::ForCurrentProcess(); 819 const CommandLine& command_line = *CommandLine::ForCurrentProcess();
820 820
821 bool enable = command_line.HasSwitch(switches::kEnableThreadedCompositing); 821 bool enable = !command_line.HasSwitch(switches::kDisableThreadedCompositing);
822 if (enable) { 822 if (enable) {
823 #if defined(OS_ANDROID) 823 #if defined(OS_ANDROID)
824 if (SynchronousCompositorFactory* factory = 824 if (SynchronousCompositorFactory* factory =
825 SynchronousCompositorFactory::GetInstance()) 825 SynchronousCompositorFactory::GetInstance())
826 compositor_message_loop_proxy_ = 826 compositor_message_loop_proxy_ =
827 factory->GetCompositorMessageLoop(); 827 factory->GetCompositorMessageLoop();
828 #endif 828 #endif
829 if (!compositor_message_loop_proxy_.get()) { 829 if (!compositor_message_loop_proxy_.get()) {
830 compositor_thread_.reset(new base::Thread("Compositor")); 830 compositor_thread_.reset(new base::Thread("Compositor"));
831 compositor_thread_->Start(); 831 compositor_thread_->Start();
(...skipping 776 matching lines...) Expand 10 before | Expand all | Expand 10 after
1608 hidden_widget_count_--; 1608 hidden_widget_count_--;
1609 1609
1610 if (!GetContentClient()->renderer()->RunIdleHandlerWhenWidgetsHidden()) { 1610 if (!GetContentClient()->renderer()->RunIdleHandlerWhenWidgetsHidden()) {
1611 return; 1611 return;
1612 } 1612 }
1613 1613
1614 ScheduleIdleHandler(kLongIdleHandlerDelayMs); 1614 ScheduleIdleHandler(kLongIdleHandlerDelayMs);
1615 } 1615 }
1616 1616
1617 } // namespace content 1617 } // namespace content
OLDNEW
« no previous file with comments | « content/public/common/content_switches.cc ('k') | content/renderer/render_thread_impl_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698