Commit f7d1d63f authored by jif@chromium.org's avatar jif@chromium.org

Use [UIScreen mainScreen] instead of [[UIScreen screens] objectAtIndex:0].

BUG=338626

Review URL: https://codereview.chromium.org/256813002

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@266686 0039d316-1c4b-4281-b951-d872f2087c98
parent b9e6bdf4
......@@ -69,7 +69,8 @@ class ScreenIos : public gfx::Screen {
// Returns the primary display.
virtual gfx::Display GetPrimaryDisplay() const OVERRIDE {
UIScreen* mainScreen = [[UIScreen screens] objectAtIndex:0];
UIScreen* mainScreen = [UIScreen mainScreen];
CHECK(mainScreen);
gfx::Display display(0, gfx::Rect(mainScreen.bounds));
display.set_device_scale_factor([mainScreen scale]);
return display;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment