Skip to content

Commit

Permalink
Remove context parameter from BadgeDrawable#getContentDescription(Con…
Browse files Browse the repository at this point in the history
…text)

PiperOrigin-RevId: 251492075
  • Loading branch information
wcshi authored and melaniegoetz committed Jun 10, 2019
1 parent cb5430e commit 6aab297
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -502,7 +502,7 @@ public void setContentDescriptionQuantityStringsResource(@StringRes int stringsR
}

@Nullable
public CharSequence getContentDescription(Context context) {
public CharSequence getContentDescription() {
if (!isVisible()) {
return null;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -273,7 +273,7 @@ public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
customContentDescription = itemData.getContentDescription();
}
info.setContentDescription(
customContentDescription + ", " + badgeDrawable.getContentDescription(getContext()));
customContentDescription + ", " + badgeDrawable.getContentDescription());
}
}

Expand Down
2 changes: 1 addition & 1 deletion lib/java/com/google/android/material/tabs/TabLayout.java
Original file line number Diff line number Diff line change
Expand Up @@ -2367,7 +2367,7 @@ public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
if (badgeDrawable != null && badgeDrawable.isVisible()) {
CharSequence customContentDescription = getContentDescription();
info.setContentDescription(
customContentDescription + ", " + badgeDrawable.getContentDescription(getContext()));
customContentDescription + ", " + badgeDrawable.getContentDescription());
}
}

Expand Down

0 comments on commit 6aab297

Please sign in to comment.