| 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 "ui/aura/mus/window_tree_host_mus.h" | 5 #include "ui/aura/mus/window_tree_host_mus.h" |
| 6 | 6 |
| 7 #include "base/memory/ptr_util.h" | 7 #include "base/memory/ptr_util.h" |
| 8 #include "ui/aura/env.h" | 8 #include "ui/aura/env.h" |
| 9 #include "ui/aura/mus/input_method_mus.h" | 9 #include "ui/aura/mus/input_method_mus.h" |
| 10 #include "ui/aura/mus/window_port_mus.h" | 10 #include "ui/aura/mus/window_port_mus.h" |
| (...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 95 WindowTreeHostMus::~WindowTreeHostMus() { | 95 WindowTreeHostMus::~WindowTreeHostMus() { |
| 96 DestroyCompositor(); | 96 DestroyCompositor(); |
| 97 DestroyDispatcher(); | 97 DestroyDispatcher(); |
| 98 } | 98 } |
| 99 | 99 |
| 100 void WindowTreeHostMus::SetBoundsFromServer(const gfx::Rect& bounds) { | 100 void WindowTreeHostMus::SetBoundsFromServer(const gfx::Rect& bounds) { |
| 101 base::AutoReset<bool> resetter(&in_set_bounds_from_server_, true); | 101 base::AutoReset<bool> resetter(&in_set_bounds_from_server_, true); |
| 102 SetBounds(bounds); | 102 SetBounds(bounds); |
| 103 } | 103 } |
| 104 | 104 |
| 105 void WindowTreeHostMus::SetClientArea(const gfx::Insets& insets) { |
| 106 delegate_->OnWindowTreeHostClientAreaWillChange(this, insets); |
| 107 } |
| 108 |
| 109 void WindowTreeHostMus::ClearHitTestMask() { |
| 110 delegate_->OnWindowTreeHostClearHitTestMask(this); |
| 111 } |
| 112 |
| 113 void WindowTreeHostMus::SetHitTestMask(const gfx::Rect& rect) { |
| 114 delegate_->OnWindowTreeHostHitTestMaskWillChange(this, rect); |
| 115 } |
| 116 |
| 105 display::Display WindowTreeHostMus::GetDisplay() const { | 117 display::Display WindowTreeHostMus::GetDisplay() const { |
| 106 for (const display::Display& display : | 118 for (const display::Display& display : |
| 107 display::Screen::GetScreen()->GetAllDisplays()) { | 119 display::Screen::GetScreen()->GetAllDisplays()) { |
| 108 if (display.id() == display_id_) | 120 if (display.id() == display_id_) |
| 109 return display; | 121 return display; |
| 110 } | 122 } |
| 111 return display::Display(); | 123 return display::Display(); |
| 112 } | 124 } |
| 113 | 125 |
| 114 void WindowTreeHostMus::ShowImpl() { | 126 void WindowTreeHostMus::ShowImpl() { |
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 146 void WindowTreeHostMus::OnCloseRequest() { | 158 void WindowTreeHostMus::OnCloseRequest() { |
| 147 OnHostCloseRequested(); | 159 OnHostCloseRequested(); |
| 148 } | 160 } |
| 149 | 161 |
| 150 gfx::ICCProfile WindowTreeHostMus::GetICCProfileForCurrentDisplay() { | 162 gfx::ICCProfile WindowTreeHostMus::GetICCProfileForCurrentDisplay() { |
| 151 // TODO: This should read the profile from mus. crbug.com/647510 | 163 // TODO: This should read the profile from mus. crbug.com/647510 |
| 152 return gfx::ICCProfile(); | 164 return gfx::ICCProfile(); |
| 153 } | 165 } |
| 154 | 166 |
| 155 } // namespace aura | 167 } // namespace aura |
| OLD | NEW |