diff --git a/atom/browser/ui/views/autofill_popup_view.cc b/atom/browser/ui/views/autofill_popup_view.cc index cbb11bba855c..1d1d7f4f12a7 100644 --- a/atom/browser/ui/views/autofill_popup_view.cc +++ b/atom/browser/ui/views/autofill_popup_view.cc @@ -19,7 +19,7 @@ namespace atom { void AutofillPopupChildView::GetAccessibleNodeData(ui::AXNodeData* node_data) { - node_data->role = ui::AX_ROLE_MENU_ITEM; + node_data->role = ax::mojom::Role::kMenuItem; node_data->SetName(suggestion_); } @@ -98,7 +98,7 @@ void AutofillPopupView::Show() { auto* host = popup_->frame_host_->GetRenderViewHost()->GetWidget(); host->AddKeyPressEventCallback(keypress_callback_); - NotifyAccessibilityEvent(ui::AX_EVENT_MENU_START, true); + NotifyAccessibilityEvent(ax::mojom::Event::kMenuStart, true); } void AutofillPopupView::Hide() { @@ -109,7 +109,7 @@ void AutofillPopupView::Hide() { } RemoveObserver(); - NotifyAccessibilityEvent(ui::AX_EVENT_MENU_END, true); + NotifyAccessibilityEvent(ax::mojom::Event::kMenuEnd, true); if (GetWidget()) { GetWidget()->Close(); @@ -152,7 +152,8 @@ void AutofillPopupView::OnSelectedRowChanged( int selected = current_row_selection.value_or(-1); if (selected == -1 || selected >= child_count()) return; - child_at(selected)->NotifyAccessibilityEvent(ui::AX_EVENT_SELECTION, true); + child_at(selected)->NotifyAccessibilityEvent(ax::mojom::Event::kSelection, + true); } } @@ -260,7 +261,7 @@ void AutofillPopupView::OnPaint(gfx::Canvas* canvas) { } void AutofillPopupView::GetAccessibleNodeData(ui::AXNodeData* node_data) { - node_data->role = ui::AX_ROLE_MENU; + node_data->role = ax::mojom::Role::kMenu; node_data->SetName("Autofill Menu"); } diff --git a/brightray/browser/views/views_delegate.cc b/brightray/browser/views/views_delegate.cc index 061feee552a6..233a595eb38a 100644 --- a/brightray/browser/views/views_delegate.cc +++ b/brightray/browser/views/views_delegate.cc @@ -46,7 +46,7 @@ bool ViewsDelegate::GetSavedWindowPlacement( } void ViewsDelegate::NotifyAccessibilityEvent(views::View* view, - ui::AXEvent event_type) {} + ax::mojom::Event event_type) {} void ViewsDelegate::NotifyMenuItemFocused(const base::string16& menu_name, const base::string16& menu_item_name, diff --git a/brightray/browser/views/views_delegate.h b/brightray/browser/views/views_delegate.h index cebe55398b0f..66c47b654ba1 100644 --- a/brightray/browser/views/views_delegate.h +++ b/brightray/browser/views/views_delegate.h @@ -28,7 +28,7 @@ class ViewsDelegate : public views::ViewsDelegate { gfx::Rect* bounds, ui::WindowShowState* show_state) const override; void NotifyAccessibilityEvent(views::View* view, - ui::AXEvent event_type) override; + ax::mojom::Event event_type) override; void NotifyMenuItemFocused(const base::string16& menu_name, const base::string16& menu_item_name, int item_index,