| OLD | NEW |
| 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 "blimp/engine/app/ui/blimp_screen.h" | 5 #include "blimp/engine/app/ui/blimp_screen.h" |
| 6 | 6 |
| 7 #include "ui/aura/window.h" | 7 #include "ui/aura/window.h" |
| 8 #include "ui/aura/window_tree_host.h" | 8 #include "ui/aura/window_tree_host.h" |
| 9 #include "ui/display/display_observer.h" | 9 #include "ui/display/display_observer.h" |
| 10 #include "ui/gfx/geometry/size.h" | 10 #include "ui/gfx/geometry/size.h" |
| (...skipping 29 matching lines...) Expand all Loading... |
| 40 display_.SetScaleAndBounds(scale, gfx::Rect(size)); | 40 display_.SetScaleAndBounds(scale, gfx::Rect(size)); |
| 41 | 41 |
| 42 FOR_EACH_OBSERVER(display::DisplayObserver, observers_, | 42 FOR_EACH_OBSERVER(display::DisplayObserver, observers_, |
| 43 OnDisplayMetricsChanged(display_, metrics)); | 43 OnDisplayMetricsChanged(display_, metrics)); |
| 44 } | 44 } |
| 45 | 45 |
| 46 gfx::Point BlimpScreen::GetCursorScreenPoint() { | 46 gfx::Point BlimpScreen::GetCursorScreenPoint() { |
| 47 return gfx::Point(); | 47 return gfx::Point(); |
| 48 } | 48 } |
| 49 | 49 |
| 50 gfx::NativeWindow BlimpScreen::GetWindowUnderCursor() { | 50 bool BlimpScreen::IsWindowUnderCursor(gfx::NativeWindow window) { |
| 51 NOTIMPLEMENTED(); | 51 NOTIMPLEMENTED(); |
| 52 return gfx::NativeWindow(nullptr); | 52 return false; |
| 53 } | 53 } |
| 54 | 54 |
| 55 gfx::NativeWindow BlimpScreen::GetWindowAtScreenPoint(const gfx::Point& point) { | 55 gfx::NativeWindow BlimpScreen::GetWindowAtScreenPoint(const gfx::Point& point) { |
| 56 return window_tree_host_ | 56 return window_tree_host_ |
| 57 ? window_tree_host_->window()->GetTopWindowContainingPoint(point) | 57 ? window_tree_host_->window()->GetTopWindowContainingPoint(point) |
| 58 : gfx::NativeWindow(nullptr); | 58 : gfx::NativeWindow(nullptr); |
| 59 } | 59 } |
| 60 | 60 |
| 61 int BlimpScreen::GetNumDisplays() const { | 61 int BlimpScreen::GetNumDisplays() const { |
| 62 return kNumDisplays; | 62 return kNumDisplays; |
| (...skipping 25 matching lines...) Expand all Loading... |
| 88 void BlimpScreen::AddObserver(display::DisplayObserver* observer) { | 88 void BlimpScreen::AddObserver(display::DisplayObserver* observer) { |
| 89 observers_.AddObserver(observer); | 89 observers_.AddObserver(observer); |
| 90 } | 90 } |
| 91 | 91 |
| 92 void BlimpScreen::RemoveObserver(display::DisplayObserver* observer) { | 92 void BlimpScreen::RemoveObserver(display::DisplayObserver* observer) { |
| 93 observers_.RemoveObserver(observer); | 93 observers_.RemoveObserver(observer); |
| 94 } | 94 } |
| 95 | 95 |
| 96 } // namespace engine | 96 } // namespace engine |
| 97 } // namespace blimp | 97 } // namespace blimp |
| OLD | NEW |