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

Unified Diff: ash/wm/window_state_observer.h

Issue 149303003: [Refactor] Move the logic to update bounds for show type from WorkspaceLayoutManager to DefaultState (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: handle show_inactive Created 6 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/wm/window_state.cc ('k') | ash/wm/wm_types.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/wm/window_state_observer.h
diff --git a/ash/wm/window_state_observer.h b/ash/wm/window_state_observer.h
index f177d5fbeba817fdc69f8d2b0e5c411680a6c029..2b30823b8f772a10b0879322a6341a0076431626 100644
--- a/ash/wm/window_state_observer.h
+++ b/ash/wm/window_state_observer.h
@@ -14,12 +14,24 @@ class WindowState;
class ASH_EXPORT WindowStateObserver {
public:
- // Called when the window's show type has changed. This is different from
- // kWindowShowStatekey property change as this will be invoked when the window
+ // Following observer methods are different from kWindowShowStatekey
+ // property change as they will be invoked when the window
// gets left/right maximized, and auto positioned. |old_type| is the value
// before the change.
- virtual void OnWindowShowTypeChanged(WindowState* window_state,
- WindowShowType old_type) {}
+
+ // Called after the window's show type is set to new type, but before
+ // the window's bounds has been updated for the new type.
+ // This is used to update the shell state such as work area so
+ // that the window can use the correct environment to update its bounds.
+ // TODO(oshima): Remove this once docked windows has its own state.
+ virtual void OnPreWindowShowTypeChange(WindowState* window_state,
+ WindowShowType old_type) {}
+
+ // Called after the window's state has been changed for the new show type.
+ // This is used to update the shell state that depends on the update
+ // window bounds, such as shelf visibility.
+ virtual void OnPostWindowShowTypeChange(WindowState* window_state,
+ WindowShowType old_type) {}
};
} // namespace wm
« no previous file with comments | « ash/wm/window_state.cc ('k') | ash/wm/wm_types.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698