Index: ui/events/cocoa/events_mac_unittest.mm |
diff --git a/ui/events/cocoa/events_mac_unittest.mm b/ui/events/cocoa/events_mac_unittest.mm |
index c4169bf80de7729064c57b1db26a9544d4e46957..ff943b9f3de0b1d4727aa2b419c3aa15d5612cf9 100644 |
--- a/ui/events/cocoa/events_mac_unittest.mm |
+++ b/ui/events/cocoa/events_mac_unittest.mm |
@@ -109,7 +109,7 @@ class EventsMacTest : public CocoaTest { |
NSPointFromCGPoint(Flip(window_location).ToCGPoint()); |
NSPoint screen_point = [test_window() convertBaseToScreen:window_point]; |
CGFloat primary_screen_height = |
- NSHeight([[[NSScreen screens] objectAtIndex:0] frame]); |
+ NSHeight([[[NSScreen screens] firstObject] frame]); |
screen_point.y = primary_screen_height - screen_point.y; |
CGEventSetLocation(scroll, NSPointToCGPoint(screen_point)); |
return [NSEvent eventWithCGEvent:scroll]; |