Package com.vaadin.client.widgets
Class Escalator.AriaGridHelper
- java.lang.Object
-
- com.vaadin.client.widgets.Escalator.AriaGridHelper
-
- Enclosing class:
- Escalator
public class Escalator.AriaGridHelper extends Object
Helper class that helps to implement the WAI-ARIA functionality for the Grid and TreeGrid component.The following WAI-ARIA attributes are added through this class:
- aria-rowcount (since 8.2)
- roles provided by
Escalator.AriaGridRole
(since 8.2)
- Since:
- 8.2
-
-
Constructor Summary
Constructors Constructor Description AriaGridHelper()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addRows(int numberOfRows)
Adds the given numberOfRows to allRows and callsupdateAriaRowCount()
.void
removeRows(int numberOfRows)
Removes the given numberOfRows from allRows and callsupdateAriaRowCount()
.void
updateAriaRowCount()
void
updateRole(com.google.gwt.dom.client.Element element, Escalator.AriaGridRole role)
Sets therole
attribute to the given element.
-
-
-
Method Detail
-
addRows
public void addRows(int numberOfRows)
Adds the given numberOfRows to allRows and callsupdateAriaRowCount()
.- Parameters:
numberOfRows
- number of rows that were added to the grid- Since:
- 8.2
-
removeRows
public void removeRows(int numberOfRows)
Removes the given numberOfRows from allRows and callsupdateAriaRowCount()
.- Parameters:
numberOfRows
- number of rows that were removed from the grid- Since:
- 8.2
-
updateAriaRowCount
public void updateAriaRowCount()
Sets the aria-rowcount attribute with the current value ofallRows
if the grid is attached andallRows
> 0.- Since:
- 8.2
-
updateRole
public void updateRole(com.google.gwt.dom.client.Element element, Escalator.AriaGridRole role)
Sets therole
attribute to the given element.- Parameters:
element
- element that should get the role attributerole
- role to be added- Since:
- 8.2
-
-