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

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: . Created 6 years, 6 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 718 matching lines...) Expand 10 before | Expand all | Expand 10 after
729 729
730 void RenderThreadImpl::EnsureWebKitInitialized() { 730 void RenderThreadImpl::EnsureWebKitInitialized() {
731 if (webkit_platform_support_) 731 if (webkit_platform_support_)
732 return; 732 return;
733 733
734 webkit_platform_support_.reset(new RendererWebKitPlatformSupportImpl); 734 webkit_platform_support_.reset(new RendererWebKitPlatformSupportImpl);
735 blink::initialize(webkit_platform_support_.get()); 735 blink::initialize(webkit_platform_support_.get());
736 736
737 const CommandLine& command_line = *CommandLine::ForCurrentProcess(); 737 const CommandLine& command_line = *CommandLine::ForCurrentProcess();
738 738
739 bool enable = command_line.HasSwitch(switches::kEnableThreadedCompositing); 739 bool enable = !command_line.HasSwitch(switches::kDisableThreadedCompositing);
740 if (enable) { 740 if (enable) {
741 #if defined(OS_ANDROID) 741 #if defined(OS_ANDROID)
742 if (SynchronousCompositorFactory* factory = 742 if (SynchronousCompositorFactory* factory =
743 SynchronousCompositorFactory::GetInstance()) 743 SynchronousCompositorFactory::GetInstance())
744 compositor_message_loop_proxy_ = 744 compositor_message_loop_proxy_ =
745 factory->GetCompositorMessageLoop(); 745 factory->GetCompositorMessageLoop();
746 #endif 746 #endif
747 if (!compositor_message_loop_proxy_.get()) { 747 if (!compositor_message_loop_proxy_.get()) {
748 compositor_thread_.reset(new base::Thread("Compositor")); 748 compositor_thread_.reset(new base::Thread("Compositor"));
749 compositor_thread_->Start(); 749 compositor_thread_->Start();
(...skipping 763 matching lines...) Expand 10 before | Expand all | Expand 10 after
1513 hidden_widget_count_--; 1513 hidden_widget_count_--;
1514 1514
1515 if (!GetContentClient()->renderer()->RunIdleHandlerWhenWidgetsHidden()) { 1515 if (!GetContentClient()->renderer()->RunIdleHandlerWhenWidgetsHidden()) {
1516 return; 1516 return;
1517 } 1517 }
1518 1518
1519 ScheduleIdleHandler(kLongIdleHandlerDelayMs); 1519 ScheduleIdleHandler(kLongIdleHandlerDelayMs);
1520 } 1520 }
1521 1521
1522 } // namespace content 1522 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698