Basic a11y support for ASButtonNode

This commit is contained in:
Rahul Malik
2016-03-20 18:14:58 -07:00
parent a9eaa9cc82
commit 4eb3356615
2 changed files with 18 additions and 2 deletions

View File

@@ -77,6 +77,7 @@ static BOOL _enableHitTestDebug = NO;
}
#pragma mark - Lifecycle
- (id)init
{
if (!(self = [super init]))
@@ -89,6 +90,13 @@ static BOOL _enableHitTestDebug = NO;
return self;
}
- (void)setUserInteractionEnabled:(BOOL)userInteractionEnabled
{
[super setUserInteractionEnabled:userInteractionEnabled];
self.isAccessibilityElement = userInteractionEnabled;
}
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wobjc-missing-super-calls"