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

Unified Diff: ash/shell.cc

Issue 11030017: Add context to gfx::Screen calls in support of simultaneous desktop+ash (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix new addition Created 8 years, 2 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
« no previous file with comments | « ash/shell.h ('k') | ash/system/tray/system_tray.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/shell.cc
diff --git a/ash/shell.cc b/ash/shell.cc
index 95b6f9d1fc074465b9c90c76805d54667cd16d1d..9152ddc656d2a36aa35991721a93eed5115b1e5a 100644
--- a/ash/shell.cc
+++ b/ash/shell.cc
@@ -193,7 +193,8 @@ Shell::Shell(ShellDelegate* delegate)
panel_layout_manager_(NULL),
status_area_widget_(NULL),
browser_context_(NULL) {
- gfx::Screen::SetInstance(screen_);
+ gfx::Screen::SetScreenInstance(gfx::SCREEN_TYPE_NATIVE, screen_);
+ gfx::Screen::SetScreenInstance(gfx::SCREEN_TYPE_ALTERNATE, screen_);
ui_controls::InstallUIControlsAura(internal::CreateUIControls());
#if defined(OS_CHROMEOS)
output_configurator_->AddObserver(output_configurator_animation_.get());
@@ -336,6 +337,11 @@ aura::RootWindow* Shell::GetActiveRootWindow() {
}
// static
+gfx::Screen* Shell::GetScreen() {
+ return gfx::Screen::GetScreenFor(GetPrimaryRootWindow());
+}
+
+// static
Shell::RootWindowList Shell::GetAllRootWindows() {
return Shell::GetInstance()->display_controller()->
GetAllRootWindows();
« no previous file with comments | « ash/shell.h ('k') | ash/system/tray/system_tray.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698