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

Side by Side Diff: ash/common/system/tray/hover_highlight_view.h

Issue 2477463003: Replace ui::AXViewState with AXNodeData and AXActionData (Closed)
Patch Set: Fix test Created 4 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
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_COMMON_SYSTEM_TRAY_HOVER_HIGHLIGHT_VIEW_H_ 5 #ifndef ASH_COMMON_SYSTEM_TRAY_HOVER_HIGHLIGHT_VIEW_H_
6 #define ASH_COMMON_SYSTEM_TRAY_HOVER_HIGHLIGHT_VIEW_H_ 6 #define ASH_COMMON_SYSTEM_TRAY_HOVER_HIGHLIGHT_VIEW_H_
7 7
8 #include "ash/common/system/tray/actionable_view.h" 8 #include "ash/common/system/tray/actionable_view.h"
9 #include "base/macros.h" 9 #include "base/macros.h"
10 #include "ui/gfx/font.h" 10 #include "ui/gfx/font.h"
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after
102 void set_text_default_color(SkColor color) { text_default_color_ = color; } 102 void set_text_default_color(SkColor color) { text_default_color_ = color; }
103 103
104 views::Label* text_label() { return text_label_; } 104 views::Label* text_label() { return text_label_; }
105 105
106 bool hover() const { return hover_; } 106 bool hover() const { return hover_; }
107 107
108 void set_tooltip(const base::string16& tooltip) { tooltip_ = tooltip; } 108 void set_tooltip(const base::string16& tooltip) { tooltip_ = tooltip; }
109 109
110 protected: 110 protected:
111 // Overridden from views::View. 111 // Overridden from views::View.
112 void GetAccessibleState(ui::AXViewState* state) override; 112 void GetAccessibleNodeData(ui::AXNodeData* node_data) override;
113 113
114 // Sets the highlighted color on a text label if |hover| is set. 114 // Sets the highlighted color on a text label if |hover| is set.
115 void SetHoverHighlight(bool hover); 115 void SetHoverHighlight(bool hover);
116 116
117 private: 117 private:
118 // Actually adds the icon and label but does not set the layout manager 118 // Actually adds the icon and label but does not set the layout manager
119 void DoAddIconAndLabel(const gfx::ImageSkia& image, 119 void DoAddIconAndLabel(const gfx::ImageSkia& image,
120 int icon_size, 120 int icon_size,
121 const base::string16& text, 121 const base::string16& text,
122 bool highlight); 122 bool highlight);
(...skipping 25 matching lines...) Expand all
148 int custom_height_ = 0; 148 int custom_height_ = 0;
149 AccessibilityState accessibility_state_ = AccessibilityState::DEFAULT; 149 AccessibilityState accessibility_state_ = AccessibilityState::DEFAULT;
150 base::string16 tooltip_; 150 base::string16 tooltip_;
151 151
152 DISALLOW_COPY_AND_ASSIGN(HoverHighlightView); 152 DISALLOW_COPY_AND_ASSIGN(HoverHighlightView);
153 }; 153 };
154 154
155 } // namespace ash 155 } // namespace ash
156 156
157 #endif // ASH_COMMON_SYSTEM_TRAY_HOVER_HIGHLIGHT_VIEW_H_ 157 #endif // ASH_COMMON_SYSTEM_TRAY_HOVER_HIGHLIGHT_VIEW_H_
OLDNEW
« no previous file with comments | « ash/common/system/tray/actionable_view.cc ('k') | ash/common/system/tray/hover_highlight_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698