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

Side by Side Diff: content/browser/web_contents/web_contents_impl.cc

Issue 10546113: Added a command line flag that disables force-compositing-mode and modified the about:flags entry t… (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 8 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
« no previous file with comments | « chrome/browser/gpu_util.cc ('k') | content/public/common/content_switches.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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/browser/web_contents/web_contents_impl.h" 5 #include "content/browser/web_contents/web_contents_impl.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/metrics/histogram.h" 10 #include "base/metrics/histogram.h"
(...skipping 439 matching lines...) Expand 10 before | Expand all | Expand 10 after
450 prefs.show_composited_layer_tree = 450 prefs.show_composited_layer_tree =
451 command_line.HasSwitch(switches::kShowCompositedLayerTree); 451 command_line.HasSwitch(switches::kShowCompositedLayerTree);
452 prefs.show_fps_counter = 452 prefs.show_fps_counter =
453 command_line.HasSwitch(switches::kShowFPSCounter); 453 command_line.HasSwitch(switches::kShowFPSCounter);
454 prefs.show_paint_rects = 454 prefs.show_paint_rects =
455 command_line.HasSwitch(switches::kShowPaintRects); 455 command_line.HasSwitch(switches::kShowPaintRects);
456 prefs.accelerated_compositing_enabled = 456 prefs.accelerated_compositing_enabled =
457 GpuProcessHost::gpu_enabled() && 457 GpuProcessHost::gpu_enabled() &&
458 !command_line.HasSwitch(switches::kDisableAcceleratedCompositing); 458 !command_line.HasSwitch(switches::kDisableAcceleratedCompositing);
459 prefs.force_compositing_mode = 459 prefs.force_compositing_mode =
460 command_line.HasSwitch(switches::kForceCompositingMode); 460 command_line.HasSwitch(switches::kForceCompositingMode) &&
461 !command_line.HasSwitch(switches::kDisableForceCompositingMode);
461 prefs.fixed_position_compositing_enabled = 462 prefs.fixed_position_compositing_enabled =
462 command_line.HasSwitch(switches::kEnableCompositingForFixedPosition); 463 command_line.HasSwitch(switches::kEnableCompositingForFixedPosition);
463 prefs.accelerated_2d_canvas_enabled = 464 prefs.accelerated_2d_canvas_enabled =
464 GpuProcessHost::gpu_enabled() && 465 GpuProcessHost::gpu_enabled() &&
465 !command_line.HasSwitch(switches::kDisableAccelerated2dCanvas); 466 !command_line.HasSwitch(switches::kDisableAccelerated2dCanvas);
466 prefs.deferred_2d_canvas_enabled = 467 prefs.deferred_2d_canvas_enabled =
467 !command_line.HasSwitch(switches::kDisableDeferred2dCanvas); 468 !command_line.HasSwitch(switches::kDisableDeferred2dCanvas);
468 prefs.accelerated_painting_enabled = 469 prefs.accelerated_painting_enabled =
469 GpuProcessHost::gpu_enabled() && 470 GpuProcessHost::gpu_enabled() &&
470 command_line.HasSwitch(switches::kEnableAcceleratedPainting); 471 command_line.HasSwitch(switches::kEnableAcceleratedPainting);
(...skipping 2562 matching lines...) Expand 10 before | Expand all | Expand 10 after
3033 browser_plugin_host()->embedder_render_process_host(); 3034 browser_plugin_host()->embedder_render_process_host();
3034 *embedder_container_id = browser_plugin_host()->instance_id(); 3035 *embedder_container_id = browser_plugin_host()->instance_id();
3035 int embedder_process_id = 3036 int embedder_process_id =
3036 embedder_render_process_host ? embedder_render_process_host->GetID() : -1; 3037 embedder_render_process_host ? embedder_render_process_host->GetID() : -1;
3037 if (embedder_process_id != -1) { 3038 if (embedder_process_id != -1) {
3038 *embedder_channel_name = 3039 *embedder_channel_name =
3039 StringPrintf("%d.r%d", render_view_host->GetProcess()->GetID(), 3040 StringPrintf("%d.r%d", render_view_host->GetProcess()->GetID(),
3040 embedder_process_id); 3041 embedder_process_id);
3041 } 3042 }
3042 } 3043 }
OLDNEW
« no previous file with comments | « chrome/browser/gpu_util.cc ('k') | content/public/common/content_switches.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698