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

Unified Diff: ash/shell.cc

Issue 10909242: Add "panel_fitting" GPU feature type and use it for mirror mode. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Addressed review comments of Patch Set 2 Created 8 years, 3 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 side-by-side diff with in-line comments
Download patch
Index: ash/shell.cc
diff --git a/ash/shell.cc b/ash/shell.cc
index 6c26a09932f17f8858fe8de9f405f693e28810ef..ede8f90a6edaaa290cf447ef32718f7b0351246a 100644
--- a/ash/shell.cc
+++ b/ash/shell.cc
@@ -100,6 +100,8 @@
#include "ash/display/output_configurator_animation.h"
#include "base/message_pump_aurax11.h"
#include "chromeos/display/output_configurator.h"
+#include "content/public/browser/gpu_data_manager.h"
+#include "content/public/common/gpu_feature_type.h"
#endif // defined(OS_CHROMEOS)
namespace ash {
@@ -193,6 +195,14 @@ Shell::Shell(ShellDelegate* delegate)
gfx::Screen::SetInstance(screen_);
ui_controls::InstallUIControlsAura(internal::CreateUIControls());
#if defined(OS_CHROMEOS)
+ content::GpuFeatureType blacklisted_features =
+ content::GpuDataManager::GetInstance()->GetBlacklistedFeatures();
+ bool is_panel_fitting_disabled =
+ (blacklisted_features & content::GPU_FEATURE_TYPE_PANEL_FITTING) ||
+ CommandLine::ForCurrentProcess()->HasSwitch(
+ switches::kAshDisablePanelFitting);
+ output_configurator_->Init(!is_panel_fitting_disabled);
+
output_configurator_->AddObserver(output_configurator_animation_.get());
base::MessagePumpAuraX11::Current()->AddDispatcherForRootWindow(
output_configurator());

Powered by Google App Engine
This is Rietveld 408576698