Chromium Code Reviews| Index: chrome/browser/ui/views/subtle_notification_view.cc |
| diff --git a/chrome/browser/ui/views/subtle_notification_view.cc b/chrome/browser/ui/views/subtle_notification_view.cc |
| index 8d42713d9d59bbfab42d6ea49c257883f5927e4d..dbe9f58ed980a5e1748663ff86b9b84b7b5688b8 100644 |
| --- a/chrome/browser/ui/views/subtle_notification_view.cc |
| +++ b/chrome/browser/ui/views/subtle_notification_view.cc |
| @@ -9,6 +9,7 @@ |
| #include "base/strings/string_split.h" |
| #include "base/strings/utf_string_conversions.h" |
| #include "third_party/skia/include/core/SkColor.h" |
| +#include "ui/accessibility/ax_view_state.h" |
| #include "ui/base/resource/resource_bundle.h" |
| #include "ui/gfx/font_list.h" |
| #include "ui/views/bubble/bubble_border.h" |
| @@ -49,6 +50,7 @@ class SubtleNotificationView::InstructionView : public views::View { |
| SkColor foreground_color, |
| SkColor background_color); |
| + base::string16 text(); |
|
tapted
2016/06/22 00:23:38
nit: declare const function
Patti Lor
2016/06/23 01:00:38
Done.
|
| void SetText(const base::string16& text); |
| private: |
| @@ -82,6 +84,10 @@ SubtleNotificationView::InstructionView::InstructionView( |
| SetText(text); |
| } |
| +base::string16 SubtleNotificationView::InstructionView::text() { |
| + return text_; |
|
tapted
2016/06/22 00:23:38
nit: declare this inline
Matt Giuca
2016/06/22 02:59:20
This needs to have the pipes removed (http://www.o
Patti Lor
2016/06/23 01:00:38
Done (as per option 2).
|
| +} |
| + |
| void SubtleNotificationView::InstructionView::SetText( |
| const base::string16& text) { |
| // Avoid replacing the contents with the same text. |
| @@ -208,3 +214,10 @@ views::Widget* SubtleNotificationView::CreatePopupWidget( |
| return popup; |
| } |
| + |
| +// views::View: |
|
tapted
2016/06/22 00:23:38
nit: no need for this comment
Patti Lor
2016/06/23 01:00:39
Done.
|
| + |
| +void SubtleNotificationView::GetAccessibleState(ui::AXViewState* state) { |
| + state->role = ui::AX_ROLE_LABEL_TEXT; |
| + state->name = instruction_view_->text(); |
|
Matt Giuca
2016/06/22 02:59:20
This needs to have the pipes removed (http://www.o
Patti Lor
2016/06/23 01:00:38
Done.
|
| +} |