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

Unified Diff: ash/wm/window_cycle_controller.h

Issue 20415002: Add window overview mode behind --ash-enable-overview-mode flag to F5 key. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Created 7 years, 5 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_animations.h ('k') | ash/wm/window_cycle_controller.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/wm/window_cycle_controller.h
diff --git a/ash/wm/window_cycle_controller.h b/ash/wm/window_cycle_controller.h
index 9f5b8be9cfbe0092609e3955ca6347601a7b6007..407dc0f400d290c033c636953bc225010bd6a662 100644
--- a/ash/wm/window_cycle_controller.h
+++ b/ash/wm/window_cycle_controller.h
@@ -9,6 +9,7 @@
#include <vector>
#include "ash/ash_export.h"
+#include "ash/wm/window_selector_delegate.h"
#include "base/basictypes.h"
#include "base/memory/scoped_ptr.h"
#include "ui/aura/client/activation_change_observer.h"
@@ -29,6 +30,7 @@ class EventHandler;
namespace ash {
class WindowCycleList;
+class WindowSelector;
// Controls cycling through windows with the keyboard, for example, via alt-tab.
// Windows are sorted primarily by most recently used, and then by screen order.
@@ -39,7 +41,8 @@ class WindowCycleList;
// order.
class ASH_EXPORT WindowCycleController
: public aura::client::ActivationChangeObserver,
- public aura::WindowObserver {
+ public aura::WindowObserver,
+ public WindowSelectorDelegate {
sky 2013/07/25 21:18:37 Is there a reason for baking the overview into thi
flackr 2013/07/25 21:34:33 Eventually, we'll use overview (WindowSelector) fo
public:
enum Direction {
FORWARD,
@@ -66,6 +69,11 @@ class ASH_EXPORT WindowCycleController
// terminate the existing multi-step cycle.
void AltKeyReleased();
+ // Enters overview mode. This is essentially the window cycling mode however
+ // not released on releasing the alt key and allows selecting with the mouse
+ // or touch rather than keypresses.
+ void ToggleOverview();
+
// Returns true if we are in the middle of a window cycling gesture.
bool IsCycling() const { return windows_.get() != NULL; }
@@ -88,6 +96,9 @@ class ASH_EXPORT WindowCycleController
const std::list<aura::Window*>* mru_windows,
bool top_most_at_end);
+ // WindowSelectorDelegate:
+ virtual void SelectWindow(aura::Window* window) OVERRIDE;
+
private:
// Call to start cycling windows. You must call StopCycling() when done.
void StartCycling();
@@ -113,6 +124,7 @@ class ASH_EXPORT WindowCycleController
virtual void OnWillRemoveWindow(aura::Window* window) OVERRIDE;
virtual void OnWindowDestroying(aura::Window* window) OVERRIDE;
+ scoped_ptr<WindowSelector> window_selector_;
scoped_ptr<WindowCycleList> windows_;
// Event handler to watch for release of alt key.
« no previous file with comments | « ash/wm/window_animations.h ('k') | ash/wm/window_cycle_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698