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

Side by Side Diff: athena/wm/mru_window_tracker.h

Issue 451363002: Revert of Split Screen mode implementation (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@split_view
Patch Set: Created 6 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 unified diff | Download patch
« no previous file with comments | « athena/wm/bezel_controller.cc ('k') | athena/wm/mru_window_tracker.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2014 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
5 #ifndef ATHENA_WM_MRU_WINDOW_TRACKER_H_
6 #define ATHENA_WM_MRU_WINDOW_TRACKER_H_
7
8 #include <list>
9
10 #include "athena/wm/public/window_list_provider.h"
11 #include "ui/aura/window_observer.h"
12
13 namespace aura {
14 class Window;
15 }
16
17 namespace athena {
18
19 // Maintains a most recently used list of windows. This is used for window
20 // cycling and overview mode.
21 class MruWindowTracker : public WindowListProvider,
22 public aura::WindowObserver {
23 public:
24 explicit MruWindowTracker(aura::Window* container);
25 virtual ~MruWindowTracker();
26
27 // Overridden from WindowListProvider
28 virtual aura::Window::Windows GetWindowList() const OVERRIDE;
29
30 // Updates the mru_windows_ list to move |window| to the front.
31 // |window| must be the child of |container_|.
32 virtual void MoveToFront(aura::Window* window) OVERRIDE;
33
34 private:
35 // Overridden from WindowObserver:
36 virtual void OnWillRemoveWindow(aura::Window* window) OVERRIDE;
37 virtual void OnWindowAdded(aura::Window* new_window) OVERRIDE;
38
39 // List of windows that have been used in the container, sorted by most
40 // recently used.
41 std::list<aura::Window*> mru_windows_;
42 aura::Window* container_;
43
44 DISALLOW_COPY_AND_ASSIGN(MruWindowTracker);
45 };
46
47 } // namespace athena
48
49 #endif // ATHENA_WM_MRU_WINDOW_TRACKER_H_
OLDNEW
« no previous file with comments | « athena/wm/bezel_controller.cc ('k') | athena/wm/mru_window_tracker.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698