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

Side by Side Diff: chromecast/graphics/cast_screen.cc

Issue 1935083003: gfx::Screen: Replace GetWindowUnderCursor() with IsWindowUnderCursor(). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Null checks Created 4 years, 7 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
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 #include "chromecast/graphics/cast_screen.h" 5 #include "chromecast/graphics/cast_screen.h"
6 6
7 #include <stdint.h> 7 #include <stdint.h>
8 8
9 #include "ui/aura/env.h" 9 #include "ui/aura/env.h"
10 #include "ui/display/screen.h" 10 #include "ui/display/screen.h"
(...skipping 30 matching lines...) Expand all
41 void CastScreen::UpdateDisplaySize(const gfx::Size& size) { 41 void CastScreen::UpdateDisplaySize(const gfx::Size& size) {
42 display_.SetScaleAndBounds(1.0f, gfx::Rect(size)); 42 display_.SetScaleAndBounds(1.0f, gfx::Rect(size));
43 if (!display_resize_cb_.is_null()) 43 if (!display_resize_cb_.is_null())
44 display_resize_cb_.Run(Size(size.width(), size.height())); 44 display_resize_cb_.Run(Size(size.width(), size.height()));
45 } 45 }
46 46
47 gfx::Point CastScreen::GetCursorScreenPoint() { 47 gfx::Point CastScreen::GetCursorScreenPoint() {
48 return aura::Env::GetInstance()->last_mouse_location(); 48 return aura::Env::GetInstance()->last_mouse_location();
49 } 49 }
50 50
51 gfx::NativeWindow CastScreen::GetWindowUnderCursor() { 51 bool CastScreen::IsWindowUnderCursor(gfx::NativeWindow window) {
52 NOTIMPLEMENTED(); 52 NOTIMPLEMENTED();
53 return gfx::NativeWindow(nullptr); 53 return false;
54 } 54 }
55 55
56 gfx::NativeWindow CastScreen::GetWindowAtScreenPoint(const gfx::Point& point) { 56 gfx::NativeWindow CastScreen::GetWindowAtScreenPoint(const gfx::Point& point) {
57 return gfx::NativeWindow(nullptr); 57 return gfx::NativeWindow(nullptr);
58 } 58 }
59 59
60 int CastScreen::GetNumDisplays() const { 60 int CastScreen::GetNumDisplays() const {
61 return 1; 61 return 1;
62 } 62 }
63 63
(...skipping 23 matching lines...) Expand all
87 void CastScreen::AddObserver(display::DisplayObserver* observer) {} 87 void CastScreen::AddObserver(display::DisplayObserver* observer) {}
88 88
89 void CastScreen::RemoveObserver(display::DisplayObserver* observer) {} 89 void CastScreen::RemoveObserver(display::DisplayObserver* observer) {}
90 90
91 CastScreen::CastScreen() : display_(kDisplayId) { 91 CastScreen::CastScreen() : display_(kDisplayId) {
92 display_.SetScaleAndBounds(1.0f, 92 display_.SetScaleAndBounds(1.0f,
93 gfx::Rect(kInitDisplayWidth, kInitDisplayHeight)); 93 gfx::Rect(kInitDisplayWidth, kInitDisplayHeight));
94 } 94 }
95 95
96 } // namespace chromecast 96 } // namespace chromecast
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698