Commit f4a4462e authored by Nektarios Paisios's avatar Nektarios Paisios Committed by Commit Bot

Removes redundant accessibility attributes from TableView

Some attributes such as ID, class name, relative bounds and visibility are automatically added by ViewAccessibility.
R=dmazzoni@chromium.org, sky@chromium.org

Change-Id: Ic27ec3f3d30e57f4e6ecd6ba2bb264650b20c887
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1918682Reviewed-by: default avatarScott Violet <sky@chromium.org>
Commit-Queue: Nektarios Paisios <nektar@chromium.org>
Cr-Commit-Position: refs/heads/master@{#715828}
parent e5e2be40
......@@ -580,9 +580,9 @@ base::string16 TableView::GetTooltipText(const gfx::Point& p) const {
}
void TableView::GetAccessibleNodeData(ui::AXNodeData* node_data) {
// ID, class name and relative bounds are added by ViewAccessibility for all
// non-virtual views, so we don't need to add them here.
node_data->role = ax::mojom::Role::kListGrid;
node_data->AddStringAttribute(ax::mojom::StringAttribute::kClassName,
GetClassName());
node_data->SetRestriction(ax::mojom::Restriction::kReadOnly);
node_data->SetDefaultActionVerb(ax::mojom::DefaultActionVerb::kActivate);
// Subclasses should overwrite the name with the control's associated label.
......@@ -592,7 +592,6 @@ void TableView::GetAccessibleNodeData(ui::AXNodeData* node_data) {
static_cast<int32_t>(GetRowCount()));
node_data->AddIntAttribute(ax::mojom::IntAttribute::kTableColumnCount,
static_cast<int32_t>(visible_columns_.size()));
node_data->relative_bounds.bounds = gfx::RectF(GetVisibleBounds());
}
bool TableView::HandleAccessibleAction(const ui::AXActionData& action_data) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment