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

Unified Diff: chrome/browser/ui/startup/startup_browser_creator_impl.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
Index: chrome/browser/ui/startup/startup_browser_creator_impl.cc
diff --git a/chrome/browser/ui/startup/startup_browser_creator_impl.cc b/chrome/browser/ui/startup/startup_browser_creator_impl.cc
index 451b0e5c5b8b01fc7719ceb7a846a9a56cd9f499..e464d715acd88ce89fefcec0d5709f91a78424a3 100644
--- a/chrome/browser/ui/startup/startup_browser_creator_impl.cc
+++ b/chrome/browser/ui/startup/startup_browser_creator_impl.cc
@@ -441,7 +441,9 @@ void StartupBrowserCreatorImpl::ExtractOptionalAppWindowSize(
std::string switch_value =
command_line_.GetSwitchValueASCII(switches::kAppWindowSize);
if (ParseCommaSeparatedIntegers(switch_value, &width, &height)) {
- const gfx::Rect work_area = gfx::Screen::GetPrimaryDisplay().work_area();
+ // TODO(scottmg): NativeScreen might be wrong. http://crbug.com/133312
+ const gfx::Rect work_area =
+ gfx::Screen::GetNativeScreen()->GetPrimaryDisplay().work_area();
width = std::min(width, work_area.width());
height = std::min(height, work_area.height());
bounds->set_size(gfx::Size(width, height));
« no previous file with comments | « chrome/browser/ui/pdf/pdf_browsertest.cc ('k') | chrome/browser/ui/views/app_list/app_list_controller_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698