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

Unified Diff: ash/common/wm/window_state.h

Issue 2240353002: move switch Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Virtual keyboard non-sticky mode changes. Created 4 years, 4 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/ash_switches.cc ('k') | ash/common/wm/window_state.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/common/wm/window_state.h
diff --git a/ash/common/wm/window_state.h b/ash/common/wm/window_state.h
index 9d4eaac8c23ad95a1c594893277dd5ef5852658f..b0812dfe4eb05f615d574d5ea0e5edc66e5d4ec2 100644
--- a/ash/common/wm/window_state.h
+++ b/ash/common/wm/window_state.h
@@ -10,6 +10,7 @@
#include "ash/ash_export.h"
#include "ash/common/wm/drag_details.h"
#include "ash/common/wm/wm_types.h"
+#include "ash/common/wm_window_observer.h"
#include "base/gtest_prod_util.h"
#include "base/macros.h"
#include "base/observer_list.h"
@@ -44,7 +45,7 @@ class WMEvent;
// Prefer using this class instead of passing aura::Window* around in
// ash code as this is often what you need to interact with, and
// accessing the window using |window()| is cheap.
-class ASH_EXPORT WindowState {
+class ASH_EXPORT WindowState : public WmWindowObserver {
public:
// A subclass of State class represents one of the window's states
// that corresponds to WindowStateType in Ash environment, e.g.
@@ -78,7 +79,7 @@ class ASH_EXPORT WindowState {
};
// Call GetWindowState() to instantiate this class.
- virtual ~WindowState();
+ ~WindowState() override;
WmWindow* window() { return window_; }
const WmWindow* window() const { return window_; }
@@ -366,6 +367,10 @@ class ASH_EXPORT WindowState {
// a cross fade animation.
void SetBoundsDirectCrossFade(const gfx::Rect& bounds);
+ // ash::WmWindowObserver
+ void OnWindowPropertyChanged(WmWindow* window,
+ WmWindowProperty property) override;
+
// The owner of this window settings.
WmWindow* window_;
std::unique_ptr<WindowStateDelegate> delegate_;
@@ -399,6 +404,9 @@ class ASH_EXPORT WindowState {
std::unique_ptr<State> current_state_;
+ // Restore bounds of window when moved by virtual keyboard.
+ gfx::Rect vk_restore_bounds_;
+
DISALLOW_COPY_AND_ASSIGN(WindowState);
};
« no previous file with comments | « ash/common/ash_switches.cc ('k') | ash/common/wm/window_state.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698