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

Unified Diff: chrome/browser/ui/views/accessibility/accessibility_event_router_views.cc

Issue 196133012: Fix incorrect use of AXState caused when refactoring two enums into one. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Add dependency Created 6 years, 9 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/views/accessibility/accessibility_event_router_views.cc
diff --git a/chrome/browser/ui/views/accessibility/accessibility_event_router_views.cc b/chrome/browser/ui/views/accessibility/accessibility_event_router_views.cc
index f3bd9c987ae43f1e8a0e2c975a2c13bd70717813..8d829153bfc6b99eb45d10328ec127eb99f01cf0 100644
--- a/chrome/browser/ui/views/accessibility/accessibility_event_router_views.cc
+++ b/chrome/browser/ui/views/accessibility/accessibility_event_router_views.cc
@@ -343,8 +343,7 @@ void AccessibilityEventRouterViews::SendTextfieldNotification(
view->GetAccessibleState(&state);
std::string name = base::UTF16ToUTF8(state.name);
std::string context = GetViewContext(view);
- bool password =
- (state.state & ui::AX_STATE_PROTECTED) != 0;
+ bool password = state.HasStateFlag(ui::AX_STATE_PROTECTED);
AccessibilityTextBoxInfo info(profile, name, context, password);
std::string value = base::UTF16ToUTF8(state.value);
info.SetValue(value, state.selection_start, state.selection_end);
@@ -379,7 +378,7 @@ void AccessibilityEventRouterViews::SendCheckboxNotification(
profile,
name,
context,
- state.state == ui::AX_STATE_CHECKED);
+ state.HasStateFlag(ui::AX_STATE_CHECKED));
SendControlAccessibilityNotification(event, &info);
}

Powered by Google App Engine
This is Rietveld 408576698