add index to tab for accessibility

This commit is contained in:
panxi 2019-04-29 17:17:21 -04:00
parent a546c5c4ac
commit 522f7a4be2
4 changed files with 4 additions and 0 deletions

View File

@ -199,6 +199,7 @@ static NSString * const COLLECTION_CELL_ID = @"cell";
NSString *accLabel = [title stringByAppendingString:[MVMCoreUIUtility hardcodedStringWithKey:@"AccTab"]];
cell.contentView.accessibilityLabel = accLabel;
cell.contentView.accessibilityValue = [NSString stringWithFormat:[MVMCoreUIUtility hardcodedStringWithKey:@"AccTabIndex"],indexPath.row + 1, [self.datasource numberOfTopTabbarItems:self]];
[cell.contentView setAccessibilityHint:[MVMCoreUIUtility hardcodedStringWithKey:@"AccTabHint"]];
if (indexPath.row == self.selectedIndex) {

View File

@ -11,6 +11,7 @@
// Tab
"AccTab" = ", tab";
"AccTabHint" = "Double tap to select.";
"AccTabIndex" = "%ld of %ld";
// top alert
"toptabbar_tab_selected" = ", tab, Selected";
"AccTopAlertClosed" = "Top alert notification is closed.";

View File

@ -10,6 +10,7 @@
// Tab
"AccTab" = ", pestaña";
"AccTabHint" = "Toca dos veces para seleccionar.";
"AccTabIndex" = "%ld de %ld";
// top alert
"toptabbar_tab_selected" = ", pestaña, Seleccionado";
"AccTopAlertClosed" = "La notificación de alerta máxima está desactivada.";

View File

@ -10,6 +10,7 @@
// Tab
"AccTab" = ", pestaña";
"AccTabHint" = "Toca dos veces para seleccionar.";
"AccTabIndex" = "%ld de %ld";
// top alert
"toptabbar_tab_selected" = ", pestaña, Seleccionado";
"AccTopAlertClosed" = "La notificación de alerta máxima está desactivada.";