Commit 862d948b authored by Tina Wang's avatar Tina Wang Committed by Commit Bot

[ios] Fix VoiceOver issue of TableViewInfoButtonCell

Previously the button won't be read and the users can't double tap to
show the popover when voiceover is on.

Bug: 1123788
Change-Id: I0e638b5f14fea8cddd67b1e7c8525b38bfd82c38
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2387151Reviewed-by: default avatarSergio Collazos <sczs@chromium.org>
Commit-Queue: Tina Wang <tinazwang@chromium.org>
Cr-Commit-Position: refs/heads/master@{#804110}
parent 4d4dd4c3
...@@ -305,9 +305,10 @@ const CGFloat kCellLabelsWidthProportion = 0.2f; ...@@ -305,9 +305,10 @@ const CGFloat kCellLabelsWidthProportion = 0.2f;
#pragma mark - UIAccessibility #pragma mark - UIAccessibility
- (CGPoint)accessibilityActivationPoint { - (CGPoint)accessibilityActivationPoint {
// Center the activation point over the button. // Center the activation point over the info button, so that double-tapping
// triggers to show the popover.
CGRect buttonFrame = UIAccessibilityConvertFrameToScreenCoordinates( CGRect buttonFrame = UIAccessibilityConvertFrameToScreenCoordinates(
self.contentView.frame, self); self.trailingButton.frame, self);
return CGPointMake(CGRectGetMidX(buttonFrame), CGRectGetMidY(buttonFrame)); return CGPointMake(CGRectGetMidX(buttonFrame), CGRectGetMidY(buttonFrame));
} }
......
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