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

Unified Diff: ui/gfx/mac/coordinate_conversion.mm

Issue 1380083005: Mac: Use [NSArray firstObject] for [NSScreen screens] (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 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 | « ui/gfx/color_profile_mac_unittest.mm ('k') | ui/gfx/mac/coordinate_conversion_unittest.mm » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/gfx/mac/coordinate_conversion.mm
diff --git a/ui/gfx/mac/coordinate_conversion.mm b/ui/gfx/mac/coordinate_conversion.mm
index 54b16e96053f4466ea9a90e6ef14221baf5ea184..b31ce9e1451b2d33a6f70f287d5fdf7d876eaff5 100644
--- a/ui/gfx/mac/coordinate_conversion.mm
+++ b/ui/gfx/mac/coordinate_conversion.mm
@@ -16,7 +16,7 @@ namespace {
// The height of the primary display, which OSX defines as the monitor with the
// menubar. This is always at index 0.
CGFloat PrimaryDisplayHeight() {
- return NSMaxY([[[NSScreen screens] objectAtIndex:0] frame]);
+ return NSMaxY([[[NSScreen screens] firstObject] frame]);
}
} // namespace
« no previous file with comments | « ui/gfx/color_profile_mac_unittest.mm ('k') | ui/gfx/mac/coordinate_conversion_unittest.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698