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

Side by Side Diff: ash/wm/overview/window_selector_item.h

Issue 676403006: Standardize usage of virtual/override/final specifiers. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 1 month 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 | « ash/wm/overview/window_selector_controller.h ('k') | ash/wm/overview/window_selector_panels.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef ASH_WM_OVERVIEW_WINDOW_SELECTOR_ITEM_H_ 5 #ifndef ASH_WM_OVERVIEW_WINDOW_SELECTOR_ITEM_H_
6 #define ASH_WM_OVERVIEW_WINDOW_SELECTOR_ITEM_H_ 6 #define ASH_WM_OVERVIEW_WINDOW_SELECTOR_ITEM_H_
7 7
8 #include "base/compiler_specific.h" 8 #include "base/compiler_specific.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "ui/aura/window_observer.h" 10 #include "ui/aura/window_observer.h"
(...skipping 12 matching lines...) Expand all
23 namespace ash { 23 namespace ash {
24 class TransparentActivateWindowButton; 24 class TransparentActivateWindowButton;
25 25
26 // This class represents an item in overview mode. An item can have one or more 26 // This class represents an item in overview mode. An item can have one or more
27 // windows, of which only one can be activated by keyboard (i.e. alt+tab) but 27 // windows, of which only one can be activated by keyboard (i.e. alt+tab) but
28 // any can be selected with a pointer (touch or mouse). 28 // any can be selected with a pointer (touch or mouse).
29 class WindowSelectorItem : public views::ButtonListener, 29 class WindowSelectorItem : public views::ButtonListener,
30 public aura::WindowObserver { 30 public aura::WindowObserver {
31 public: 31 public:
32 WindowSelectorItem(); 32 WindowSelectorItem();
33 virtual ~WindowSelectorItem(); 33 ~WindowSelectorItem() override;
34 34
35 // The time for the close buttons and labels to fade in when initially shown 35 // The time for the close buttons and labels to fade in when initially shown
36 // on entering overview mode. 36 // on entering overview mode.
37 static const int kFadeInMilliseconds; 37 static const int kFadeInMilliseconds;
38 38
39 // Returns the root window on which this item is shown. 39 // Returns the root window on which this item is shown.
40 virtual aura::Window* GetRootWindow() = 0; 40 virtual aura::Window* GetRootWindow() = 0;
41 41
42 // Returns true if the window selector item has |window| as a selectable 42 // Returns true if the window selector item has |window| as a selectable
43 // window. 43 // window.
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
81 81
82 // Sets if the item is dimmed in the overview. Changing the value will also 82 // Sets if the item is dimmed in the overview. Changing the value will also
83 // change the visibility of the transform windows. 83 // change the visibility of the transform windows.
84 virtual void SetDimmed(bool dimmed); 84 virtual void SetDimmed(bool dimmed);
85 bool dimmed() const { return dimmed_; } 85 bool dimmed() const { return dimmed_; }
86 86
87 const gfx::Rect& bounds() const { return bounds_; } 87 const gfx::Rect& bounds() const { return bounds_; }
88 const gfx::Rect& target_bounds() const { return target_bounds_; } 88 const gfx::Rect& target_bounds() const { return target_bounds_; }
89 89
90 // views::ButtonListener: 90 // views::ButtonListener:
91 virtual void ButtonPressed(views::Button* sender, 91 void ButtonPressed(views::Button* sender, const ui::Event& event) override;
92 const ui::Event& event) override;
93 92
94 // aura::WindowObserver: 93 // aura::WindowObserver:
95 virtual void OnWindowTitleChanged(aura::Window* window) override; 94 void OnWindowTitleChanged(aura::Window* window) override;
96 95
97 protected: 96 protected:
98 // Sets the bounds of this selector's items to |target_bounds| in 97 // Sets the bounds of this selector's items to |target_bounds| in
99 // |root_window|. If |animate| the windows are animated from their current 98 // |root_window|. If |animate| the windows are animated from their current
100 // location. 99 // location.
101 virtual void SetItemBounds(aura::Window* root_window, 100 virtual void SetItemBounds(aura::Window* root_window,
102 const gfx::Rect& target_bounds, 101 const gfx::Rect& target_bounds,
103 bool animate) = 0; 102 bool animate) = 0;
104 103
105 // Sets the bounds used by the selector item's windows. 104 // Sets the bounds used by the selector item's windows.
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
154 // Transparent window on top of the real windows in the overview that 153 // Transparent window on top of the real windows in the overview that
155 // activates them on click or tap. 154 // activates them on click or tap.
156 scoped_ptr<TransparentActivateWindowButton> activate_window_button_; 155 scoped_ptr<TransparentActivateWindowButton> activate_window_button_;
157 156
158 DISALLOW_COPY_AND_ASSIGN(WindowSelectorItem); 157 DISALLOW_COPY_AND_ASSIGN(WindowSelectorItem);
159 }; 158 };
160 159
161 } // namespace ash 160 } // namespace ash
162 161
163 #endif // ASH_WM_OVERVIEW_WINDOW_SELECTOR_ITEM_H_ 162 #endif // ASH_WM_OVERVIEW_WINDOW_SELECTOR_ITEM_H_
OLDNEW
« no previous file with comments | « ash/wm/overview/window_selector_controller.h ('k') | ash/wm/overview/window_selector_panels.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698