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

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

Issue 10825027: Turn on the fixed position stacking context flag by default (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 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
« no previous file with comments | « chrome/browser/about_flags.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 570 matching lines...) Expand 10 before | Expand all | Expand 10 after
581 if (command_line.HasSwitch(switches::kMaxUntiledLayerHeight)) 581 if (command_line.HasSwitch(switches::kMaxUntiledLayerHeight))
582 prefs.max_untiled_layer_height = 582 prefs.max_untiled_layer_height =
583 GetSwitchValueAsInt(command_line, switches::kMaxUntiledLayerHeight, 1); 583 GetSwitchValueAsInt(command_line, switches::kMaxUntiledLayerHeight, 1);
584 584
585 if (gfx::Screen::IsDIPEnabled()) { 585 if (gfx::Screen::IsDIPEnabled()) {
586 // Only apply when using DIP coordinate system as this setting interferes 586 // Only apply when using DIP coordinate system as this setting interferes
587 // with fixed layout mode. 587 // with fixed layout mode.
588 prefs.apply_default_device_scale_factor_in_compositor = true; 588 prefs.apply_default_device_scale_factor_in_compositor = true;
589 } 589 }
590 590
591 prefs.fixed_position_creates_stacking_context = 591 prefs.fixed_position_creates_stacking_context = !command_line.HasSwitch(
592 command_line.HasSwitch(switches::kFixedPositionCreatesStackingContext); 592 switches::kDisableFixedPositionCreatesStackingContext);
593 593
594 prefs.number_of_cpu_cores = base::SysInfo::NumberOfProcessors(); 594 prefs.number_of_cpu_cores = base::SysInfo::NumberOfProcessors();
595 595
596 content::GetContentClient()->browser()->OverrideWebkitPrefs(rvh, url, &prefs); 596 content::GetContentClient()->browser()->OverrideWebkitPrefs(rvh, url, &prefs);
597 597
598 return prefs; 598 return prefs;
599 } 599 }
600 600
601 NavigationControllerImpl& WebContentsImpl::GetControllerImpl() { 601 NavigationControllerImpl& WebContentsImpl::GetControllerImpl() {
602 return controller_; 602 return controller_;
(...skipping 2519 matching lines...) Expand 10 before | Expand all | Expand 10 after
3122 browser_plugin_host()->embedder_render_process_host(); 3122 browser_plugin_host()->embedder_render_process_host();
3123 *embedder_container_id = browser_plugin_host()->instance_id(); 3123 *embedder_container_id = browser_plugin_host()->instance_id();
3124 int embedder_process_id = 3124 int embedder_process_id =
3125 embedder_render_process_host ? embedder_render_process_host->GetID() : -1; 3125 embedder_render_process_host ? embedder_render_process_host->GetID() : -1;
3126 if (embedder_process_id != -1) { 3126 if (embedder_process_id != -1) {
3127 *embedder_channel_name = 3127 *embedder_channel_name =
3128 StringPrintf("%d.r%d", render_view_host->GetProcess()->GetID(), 3128 StringPrintf("%d.r%d", render_view_host->GetProcess()->GetID(),
3129 embedder_process_id); 3129 embedder_process_id);
3130 } 3130 }
3131 } 3131 }
OLDNEW
« no previous file with comments | « chrome/browser/about_flags.cc ('k') | content/public/common/content_switches.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698