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

Unified Diff: ash/wm/window_selector_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: Remove MRU window tracking refactoring from CL. 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
Index: ash/wm/window_selector_controller.h
diff --git a/ash/wm/window_selector_controller.h b/ash/wm/window_selector_controller.h
new file mode 100644
index 0000000000000000000000000000000000000000..8ad404fb40a74fc9d6f8530da37de1d233ab6a8f
--- /dev/null
+++ b/ash/wm/window_selector_controller.h
@@ -0,0 +1,53 @@
+// Copyright (c) 2013 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef ASH_WM_WINDOW_SELECTOR_CONTROLLER_H_
+#define ASH_WM_WINDOW_SELECTOR_CONTROLLER_H_
+
+#include <list>
+#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/window_observer.h"
+
+namespace aura {
+class Window;
+}
+
+namespace ash {
+
+class WindowSelector;
+
+// Manages a window selector which displays an overview of all windows and
+// allows selecting a window to activate it.
+class ASH_EXPORT WindowSelectorController
+ : public WindowSelectorDelegate {
+ public:
+ WindowSelectorController();
+ virtual ~WindowSelectorController();
+
+ // Returns true if selecting windows in an overview is enabled. This is false
+ // at certain times, such as when the lock screen is visible.
+ static bool CanSelect();
+
+ // 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();
+
+ // WindowSelectorDelegate:
+ virtual void SelectWindow(aura::Window* window) OVERRIDE;
+
+ private:
+ scoped_ptr<WindowSelector> window_selector_;
+
+ DISALLOW_COPY_AND_ASSIGN(WindowSelectorController);
+};
+
+} // namespace ash
+
+#endif // ASH_WM_WINDOW_SELECTOR_CONTROLLER_H_

Powered by Google App Engine
This is Rietveld 408576698