| Index: ash/mus/shadow_controller.cc
|
| diff --git a/mash/wm/shadow_controller.cc b/ash/mus/shadow_controller.cc
|
| similarity index 70%
|
| rename from mash/wm/shadow_controller.cc
|
| rename to ash/mus/shadow_controller.cc
|
| index 280bdaeee2151dc2402cf29cbda91b0a2787da67..91a6bc00fcacd14abdf60ac9ca3760e41e3a31c4 100644
|
| --- a/mash/wm/shadow_controller.cc
|
| +++ b/ash/mus/shadow_controller.cc
|
| @@ -2,20 +2,20 @@
|
| // Use of this source code is governed by a BSD-style license that can be
|
| // found in the LICENSE file.
|
|
|
| -#include "mash/wm/shadow_controller.h"
|
| +#include "ash/mus/shadow_controller.h"
|
|
|
| +#include "ash/mus/property_util.h"
|
| +#include "ash/mus/shadow.h"
|
| #include "components/mus/public/cpp/window.h"
|
| #include "components/mus/public/cpp/window_tree_client.h"
|
| -#include "mash/wm/property_util.h"
|
| -#include "mash/wm/shadow.h"
|
|
|
| -namespace mash {
|
| -namespace wm {
|
| +namespace ash {
|
| +namespace mus {
|
| namespace {
|
|
|
| // Returns the first ancestor of |from| (including |from|) that has a shadow.
|
| -mus::Window* FindAncestorWithShadow(mus::Window* from) {
|
| - mus::Window* result = from;
|
| +::mus::Window* FindAncestorWithShadow(::mus::Window* from) {
|
| + ::mus::Window* result = from;
|
| while (result && !GetShadow(result))
|
| result = result->parent();
|
| // Small shadows never change.
|
| @@ -25,7 +25,7 @@ mus::Window* FindAncestorWithShadow(mus::Window* from) {
|
|
|
| } // namespace
|
|
|
| -ShadowController::ShadowController(mus::WindowTreeClient* window_tree)
|
| +ShadowController::ShadowController(::mus::WindowTreeClient* window_tree)
|
| : window_tree_(window_tree), active_window_(nullptr) {
|
| window_tree_->AddObserver(this);
|
| SetActiveWindow(FindAncestorWithShadow(window_tree_->GetFocusedWindow()));
|
| @@ -37,7 +37,7 @@ ShadowController::~ShadowController() {
|
| active_window_->RemoveObserver(this);
|
| }
|
|
|
| -void ShadowController::SetActiveWindow(mus::Window* window) {
|
| +void ShadowController::SetActiveWindow(::mus::Window* window) {
|
| if (window == active_window_)
|
| return;
|
|
|
| @@ -53,15 +53,15 @@ void ShadowController::SetActiveWindow(mus::Window* window) {
|
| }
|
| }
|
|
|
| -void ShadowController::OnWindowTreeFocusChanged(mus::Window* gained_focus,
|
| - mus::Window* lost_focus) {
|
| +void ShadowController::OnWindowTreeFocusChanged(::mus::Window* gained_focus,
|
| + ::mus::Window* lost_focus) {
|
| SetActiveWindow(FindAncestorWithShadow(gained_focus));
|
| }
|
|
|
| -void ShadowController::OnWindowDestroying(mus::Window* window) {
|
| +void ShadowController::OnWindowDestroying(::mus::Window* window) {
|
| DCHECK_EQ(window, active_window_);
|
| SetActiveWindow(nullptr);
|
| }
|
|
|
| -} // namespace wm
|
| -} // namespace mash
|
| +} // namespace mus
|
| +} // namespace ash
|
|
|