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

Side by Side Diff: ash/system/tray/tray_background_view.h

Issue 515573002: Use active state on touch start for tray icons (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Update test histogram Created 6 years, 3 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 | « ash/system/overview/overview_button_tray.cc ('k') | ash/system/tray/tray_background_view.cc » ('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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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_SYSTEM_TRAY_TRAY_BACKGROUND_VIEW_H_ 5 #ifndef ASH_SYSTEM_TRAY_TRAY_BACKGROUND_VIEW_H_
6 #define ASH_SYSTEM_TRAY_TRAY_BACKGROUND_VIEW_H_ 6 #define ASH_SYSTEM_TRAY_TRAY_BACKGROUND_VIEW_H_
7 7
8 #include "ash/ash_export.h" 8 #include "ash/ash_export.h"
9 #include "ash/shelf/background_animator.h" 9 #include "ash/shelf/background_animator.h"
10 #include "ash/shelf/shelf_types.h" 10 #include "ash/shelf/shelf_types.h"
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 virtual const char* GetClassName() const OVERRIDE; 70 virtual const char* GetClassName() const OVERRIDE;
71 virtual void OnMouseEntered(const ui::MouseEvent& event) OVERRIDE; 71 virtual void OnMouseEntered(const ui::MouseEvent& event) OVERRIDE;
72 virtual void OnMouseExited(const ui::MouseEvent& event) OVERRIDE; 72 virtual void OnMouseExited(const ui::MouseEvent& event) OVERRIDE;
73 virtual void ChildPreferredSizeChanged(views::View* child) OVERRIDE; 73 virtual void ChildPreferredSizeChanged(views::View* child) OVERRIDE;
74 virtual void GetAccessibleState(ui::AXViewState* state) OVERRIDE; 74 virtual void GetAccessibleState(ui::AXViewState* state) OVERRIDE;
75 virtual void AboutToRequestFocusFromTabTraversal(bool reverse) OVERRIDE; 75 virtual void AboutToRequestFocusFromTabTraversal(bool reverse) OVERRIDE;
76 76
77 // ActionableView: 77 // ActionableView:
78 virtual bool PerformAction(const ui::Event& event) OVERRIDE; 78 virtual bool PerformAction(const ui::Event& event) OVERRIDE;
79 virtual gfx::Rect GetFocusBounds() OVERRIDE; 79 virtual gfx::Rect GetFocusBounds() OVERRIDE;
80 virtual void OnGestureEvent(ui::GestureEvent* event) OVERRIDE;
80 81
81 // BackgroundAnimatorDelegate: 82 // BackgroundAnimatorDelegate:
82 virtual void UpdateBackground(int alpha) OVERRIDE; 83 virtual void UpdateBackground(int alpha) OVERRIDE;
83 84
84 // Called whenever the shelf alignment changes. 85 // Called whenever the shelf alignment changes.
85 virtual void SetShelfAlignment(ShelfAlignment alignment); 86 virtual void SetShelfAlignment(ShelfAlignment alignment);
86 87
87 // Called when the anchor (tray or bubble) may have moved or changed. 88 // Called when the anchor (tray or bubble) may have moved or changed.
88 virtual void AnchorUpdated() {} 89 virtual void AnchorUpdated() {}
89 90
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
178 BackgroundAnimator hide_background_animator_; 179 BackgroundAnimator hide_background_animator_;
179 BackgroundAnimator hover_background_animator_; 180 BackgroundAnimator hover_background_animator_;
180 181
181 // True if the background gets hovered. 182 // True if the background gets hovered.
182 bool hovered_; 183 bool hovered_;
183 184
184 // This variable stores the activation override which will tint the background 185 // This variable stores the activation override which will tint the background
185 // differently if set to true. 186 // differently if set to true.
186 bool draw_background_as_active_; 187 bool draw_background_as_active_;
187 188
189 // True if touch view feedback command line flag has been enabled. When
190 // enabled touch gestures will toggle rendering the background as active.
191 bool touch_feedback_enabled_;
192
188 scoped_ptr<TrayWidgetObserver> widget_observer_; 193 scoped_ptr<TrayWidgetObserver> widget_observer_;
189 scoped_ptr<TrayEventFilter> tray_event_filter_; 194 scoped_ptr<TrayEventFilter> tray_event_filter_;
190 195
191 DISALLOW_COPY_AND_ASSIGN(TrayBackgroundView); 196 DISALLOW_COPY_AND_ASSIGN(TrayBackgroundView);
192 }; 197 };
193 198
194 } // namespace ash 199 } // namespace ash
195 200
196 #endif // ASH_SYSTEM_TRAY_TRAY_BACKGROUND_VIEW_H_ 201 #endif // ASH_SYSTEM_TRAY_TRAY_BACKGROUND_VIEW_H_
OLDNEW
« no previous file with comments | « ash/system/overview/overview_button_tray.cc ('k') | ash/system/tray/tray_background_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698