overview_observer.h 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. // Copyright 2019 The Chromium Authors. All rights reserved.
  2. // Use of this source code is governed by a BSD-style license that can be
  3. // found in the LICENSE file.
  4. #ifndef ASH_WM_OVERVIEW_OVERVIEW_OBSERVER_H_
  5. #define ASH_WM_OVERVIEW_OVERVIEW_OBSERVER_H_
  6. #include "ash/ash_export.h"
  7. #include "base/observer_list_types.h"
  8. namespace ash {
  9. class OverviewSession;
  10. // Used to observe overview mode changes in ash.
  11. class ASH_EXPORT OverviewObserver : public base::CheckedObserver {
  12. public:
  13. // Called when the overview mode is about to start. At this point, asking
  14. // the overview controller whether it's in overview mode will return |false|.
  15. virtual void OnOverviewModeWillStart() {}
  16. // Called when the overview mode has just started (before the windows get
  17. // re-arranged).
  18. virtual void OnOverviewModeStarting() {}
  19. // Called after the animations that happen when overview mode is started are
  20. // complete. If |canceled| it means overview was quit before the start
  21. // animations were finished.
  22. virtual void OnOverviewModeStartingAnimationComplete(bool canceled) {}
  23. // Called when the overview mode is about to end (before the windows restore
  24. // themselves). |overview_session| will not be null.
  25. virtual void OnOverviewModeEnding(OverviewSession* overview_session) {}
  26. // Called after overview mode has ended.
  27. virtual void OnOverviewModeEnded() {}
  28. // Called after the animations that happen when overview mode is ended are
  29. // complete. If |canceled| it means overview was reentered before the exit
  30. // animations were finished.
  31. virtual void OnOverviewModeEndingAnimationComplete(bool canceled) {}
  32. };
  33. } // namespace ash
  34. #endif // ASH_WM_OVERVIEW_OVERVIEW_OBSERVER_H_