Add accessibility labels to custom disclosure button

This commit is contained in:
Maurice Parker 2019-09-30 13:32:54 -05:00
parent a7bee3a6d5
commit 2c3f665b58
1 changed files with 2 additions and 0 deletions

View File

@ -117,8 +117,10 @@ class MasterFeedTableViewCell : NNWTableViewCell {
UIView.animate(withDuration: duration) { UIView.animate(withDuration: duration) {
if self.isDisclosureExpanded { if self.isDisclosureExpanded {
self.disclosureButton?.accessibilityLabel = NSLocalizedString("Collapse Folder", comment: "Collapse Folder")
self.disclosureButton?.imageView?.transform = CGAffineTransform(rotationAngle: 1.570796) self.disclosureButton?.imageView?.transform = CGAffineTransform(rotationAngle: 1.570796)
} else { } else {
self.disclosureButton?.accessibilityLabel = NSLocalizedString("Expand Folder", comment: "Expand Folder")
self.disclosureButton?.imageView?.transform = CGAffineTransform(rotationAngle: 0) self.disclosureButton?.imageView?.transform = CGAffineTransform(rotationAngle: 0)
} }
} }