OLD | NEW |
1 // Copyright (c) 2014 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2014 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 "mojo/examples/aura_demo/demo_screen.h" | 5 #include "mojo/examples/aura_demo/demo_screen.h" |
6 | 6 |
7 #include "ui/gfx/native_widget_types.h" | 7 #include "ui/gfx/native_widget_types.h" |
8 #include "ui/gfx/rect_conversions.h" | 8 #include "ui/gfx/rect_conversions.h" |
9 | 9 |
10 namespace mojo { | 10 namespace mojo { |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
43 | 43 |
44 std::vector<gfx::Display> DemoScreen::GetAllDisplays() const { | 44 std::vector<gfx::Display> DemoScreen::GetAllDisplays() const { |
45 return std::vector<gfx::Display>(1, display_); | 45 return std::vector<gfx::Display>(1, display_); |
46 } | 46 } |
47 | 47 |
48 gfx::Display DemoScreen::GetDisplayNearestWindow( | 48 gfx::Display DemoScreen::GetDisplayNearestWindow( |
49 gfx::NativeWindow window) const { | 49 gfx::NativeWindow window) const { |
50 return display_; | 50 return display_; |
51 } | 51 } |
52 | 52 |
| 53 bool DemoScreen::GetDisplayColorProfile( |
| 54 gfx::NativeWindow window, std::vector<char>* color_profile) const { |
| 55 return false; |
| 56 } |
| 57 |
53 gfx::Display DemoScreen::GetDisplayNearestPoint(const gfx::Point& point) const { | 58 gfx::Display DemoScreen::GetDisplayNearestPoint(const gfx::Point& point) const { |
54 return display_; | 59 return display_; |
55 } | 60 } |
56 | 61 |
57 gfx::Display DemoScreen::GetDisplayMatching(const gfx::Rect& match_rect) const { | 62 gfx::Display DemoScreen::GetDisplayMatching(const gfx::Rect& match_rect) const { |
58 return display_; | 63 return display_; |
59 } | 64 } |
60 | 65 |
61 gfx::Display DemoScreen::GetPrimaryDisplay() const { | 66 gfx::Display DemoScreen::GetPrimaryDisplay() const { |
62 return display_; | 67 return display_; |
63 } | 68 } |
64 | 69 |
65 void DemoScreen::AddObserver(gfx::DisplayObserver* observer) { | 70 void DemoScreen::AddObserver(gfx::DisplayObserver* observer) { |
66 } | 71 } |
67 | 72 |
68 void DemoScreen::RemoveObserver(gfx::DisplayObserver* observer) { | 73 void DemoScreen::RemoveObserver(gfx::DisplayObserver* observer) { |
69 } | 74 } |
70 | 75 |
71 DemoScreen::DemoScreen(const gfx::Rect& screen_bounds) { | 76 DemoScreen::DemoScreen(const gfx::Rect& screen_bounds) { |
72 static int64 synthesized_display_id = 2000; | 77 static int64 synthesized_display_id = 2000; |
73 display_.set_id(synthesized_display_id++); | 78 display_.set_id(synthesized_display_id++); |
74 display_.SetScaleAndBounds(1.0f, screen_bounds); | 79 display_.SetScaleAndBounds(1.0f, screen_bounds); |
75 } | 80 } |
76 | 81 |
77 } // namespace examples | 82 } // namespace examples |
78 } // namespace mojo | 83 } // namespace mojo |
OLD | NEW |