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

Unified Diff: ash/common/frame/custom_frame_view_ash.cc

Issue 2699033002: Replace WmWindowObserver with aura::WindowObserver. (Closed)
Patch Set: Check for null images in ShelfWindowWatcher. Created 3 years, 10 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ash/common/devtools/ash_devtools_dom_agent.cc ('k') | ash/common/shelf/shelf_window_watcher.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/common/frame/custom_frame_view_ash.cc
diff --git a/ash/common/frame/custom_frame_view_ash.cc b/ash/common/frame/custom_frame_view_ash.cc
index ac441c4327cdc2c4d935cca9f3512a85e1b3b5a6..d75b7287c3d1a2cf3d75da93b3da520077363e28 100644
--- a/ash/common/frame/custom_frame_view_ash.cc
+++ b/ash/common/frame/custom_frame_view_ash.cc
@@ -16,10 +16,11 @@
#include "ash/common/wm_lookup.h"
#include "ash/common/wm_shell.h"
#include "ash/common/wm_window.h"
-#include "ash/common/wm_window_observer.h"
#include "ash/common/wm_window_property.h"
#include "ash/shared/immersive_fullscreen_controller.h"
#include "ash/shared/immersive_fullscreen_controller_delegate.h"
+#include "ui/aura/window.h"
+#include "ui/aura/window_observer.h"
#include "ui/gfx/geometry/rect.h"
#include "ui/gfx/geometry/rect_conversions.h"
#include "ui/gfx/geometry/size.h"
@@ -40,7 +41,7 @@ namespace {
// windows.
class CustomFrameViewAshWindowStateDelegate : public wm::WindowStateDelegate,
public wm::WindowStateObserver,
- public WmWindowObserver {
+ public aura::WindowObserver {
public:
CustomFrameViewAshWindowStateDelegate(wm::WindowState* window_state,
CustomFrameViewAsh* custom_frame_view,
@@ -53,7 +54,7 @@ class CustomFrameViewAshWindowStateDelegate : public wm::WindowStateDelegate,
// TODO(pkotwicz): This is a hack. Remove ASAP. http://crbug.com/319048
window_state_ = window_state;
window_state_->AddObserver(this);
- window_state_->window()->AddObserver(this);
+ window_state_->window()->aura_window()->AddObserver(this);
if (!enable_immersive)
return;
@@ -68,7 +69,7 @@ class CustomFrameViewAshWindowStateDelegate : public wm::WindowStateDelegate,
~CustomFrameViewAshWindowStateDelegate() override {
if (window_state_) {
window_state_->RemoveObserver(this);
- window_state_->window()->RemoveObserver(this);
+ window_state_->window()->aura_window()->RemoveObserver(this);
}
}
@@ -86,8 +87,8 @@ class CustomFrameViewAshWindowStateDelegate : public wm::WindowStateDelegate,
}
return true;
}
- // Overridden from WmWindowObserver:
- void OnWindowDestroying(WmWindow* window) override {
+ // Overridden from aura::WindowObserver:
+ void OnWindowDestroying(aura::Window* window) override {
window_state_->RemoveObserver(this);
window->RemoveObserver(this);
window_state_ = nullptr;
« no previous file with comments | « ash/common/devtools/ash_devtools_dom_agent.cc ('k') | ash/common/shelf/shelf_window_watcher.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698