Refactor to MobileAccessibility.postNotification to accept other notification types

MobileAccessibility.postNotification now allows you to send
UIAccessibilityScreenChangedNotification,
UIAccessibilityLayoutChangedNotification, and
UIAccessibilityPageScrolledNotification in addition to
UIAccessibilityAnnouncementNotification.

Refactor isVoiceOverRunning and “voiceoverstatuschanged” to the more
platform agnostic isScreenReaderRunning and “screenreaderstatuschanged”
in anticipation of Android support.
This commit is contained in:
Michael Jordan
2014-01-22 17:35:30 -05:00
parent 3fa548ec84
commit a7448daaf1
3 changed files with 78 additions and 46 deletions
+4 -4
View File
@@ -23,7 +23,7 @@
NSString* callbackId;
NSString* commandCallbackId;
BOOL voiceOverRunning;
BOOL closeCaptioningEnabled;
BOOL closedCaptioningEnabled;
BOOL guidedAccessEnabled;
BOOL invertColorsEnabled;
BOOL monoAudioEnabled;
@@ -32,17 +32,17 @@
@property (strong) NSString* callbackId;
@property (strong) NSString* commandCallbackId;
@property BOOL voiceOverRunning;
@property BOOL closeCaptioningEnabled;
@property BOOL closedCaptioningEnabled;
@property BOOL guidedAccessEnabled;
@property BOOL invertColorsEnabled;
@property BOOL monoAudioEnabled;
- (void) isVoiceOverRunning:(CDVInvokedUrlCommand*)command;
- (void) isScreenReaderRunning:(CDVInvokedUrlCommand*)command;
- (void) isClosedCaptioningEnabled:(CDVInvokedUrlCommand*)command;
- (void) isGuidedAccessEnabled:(CDVInvokedUrlCommand*)command;
- (void) isInvertColorsEnabled:(CDVInvokedUrlCommand*)command;
- (void) isMonoAudioEnabled:(CDVInvokedUrlCommand*)command;
- (void) postAnnouncementNotification:(CDVInvokedUrlCommand*)command;
- (void) postNotification:(CDVInvokedUrlCommand*)command;
- (void) start:(CDVInvokedUrlCommand*)command;
- (void) stop:(CDVInvokedUrlCommand*)command;