You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@weex.apache.org by ac...@apache.org on 2017/08/24 10:35:57 UTC
[09/24] incubator-weex git commit: * [ios] fix picker manager
accessibility
* [ios] fix picker manager accessibility
Project: http://git-wip-us.apache.org/repos/asf/incubator-weex/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-weex/commit/fbbc23e2
Tree: http://git-wip-us.apache.org/repos/asf/incubator-weex/tree/fbbc23e2
Diff: http://git-wip-us.apache.org/repos/asf/incubator-weex/diff/fbbc23e2
Branch: refs/heads/0.16-dev
Commit: fbbc23e25c9d36bbbf7e151405b3ba194faf8862
Parents: d9c40da
Author: acton393 <zh...@gmail.com>
Authored: Tue Aug 15 11:08:05 2017 +0800
Committer: acton393 <zh...@gmail.com>
Committed: Tue Aug 15 11:08:05 2017 +0800
----------------------------------------------------------------------
ios/sdk/WeexSDK/Sources/Manager/WXDatePickerManager.m | 8 ++++++++
1 file changed, 8 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-weex/blob/fbbc23e2/ios/sdk/WeexSDK/Sources/Manager/WXDatePickerManager.m
----------------------------------------------------------------------
diff --git a/ios/sdk/WeexSDK/Sources/Manager/WXDatePickerManager.m b/ios/sdk/WeexSDK/Sources/Manager/WXDatePickerManager.m
index 73c5d3c..d671634 100644
--- a/ios/sdk/WeexSDK/Sources/Manager/WXDatePickerManager.m
+++ b/ios/sdk/WeexSDK/Sources/Manager/WXDatePickerManager.m
@@ -150,6 +150,7 @@
{
UIWindow *window = [UIApplication sharedApplication].keyWindow;
[window addSubview:self.backgroudView];
+ UIAccessibilityPostNotification(UIAccessibilityScreenChangedNotification, self.datePicker);
if(self.isAnimating)
{
return;
@@ -178,6 +179,13 @@
self.backgroudView.hidden = YES;
self.isAnimating = NO;
[self.backgroudView removeFromSuperview];
+
+ // move focus to original view;
+ if ([self.delegate isKindOfClass:[WXComponent class]]) {
+ UIAccessibilityPostNotification(UIAccessibilityScreenChangedNotification, ((WXComponent*)self.delegate).view);
+ }else if ([self.delegate isKindOfClass:[UIView class]]) {
+ UIAccessibilityPostNotification(UIAccessibilityScreenChangedNotification, (UIView*)self.delegate);
+ }
}];
}