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

Side by Side Diff: ui/display/ios/screen_ios.mm

Issue 2751833004: Reland "Add display::GetDisplayNearestView" (Closed)
Patch Set: Created 3 years, 9 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 unified diff | Download patch
« no previous file with comments | « ui/display/BUILD.gn ('k') | ui/display/mac/screen_mac.mm » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #import <UIKit/UIKit.h> 5 #import <UIKit/UIKit.h>
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "ui/display/display.h" 8 #include "ui/display/display.h"
9 #include "ui/display/screen_base.h" 9 #include "ui/display/screen_base.h"
10 10
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
44 return [[UIScreen screens] count]; 44 return [[UIScreen screens] count];
45 #endif 45 #endif
46 } 46 }
47 47
48 private: 48 private:
49 DISALLOW_COPY_AND_ASSIGN(ScreenIos); 49 DISALLOW_COPY_AND_ASSIGN(ScreenIos);
50 }; 50 };
51 51
52 } // namespace 52 } // namespace
53 53
54 // static
55 gfx::NativeWindow Screen::GetWindowForView(gfx::NativeView view) {
56 return [view window];
57 }
58
54 Screen* CreateNativeScreen() { 59 Screen* CreateNativeScreen() {
55 return new ScreenIos; 60 return new ScreenIos;
56 } 61 }
57 62
58 } // namespace gfx 63 } // namespace gfx
OLDNEW
« no previous file with comments | « ui/display/BUILD.gn ('k') | ui/display/mac/screen_mac.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698