From 39a78087890fb9255a5e47220bac6cfb956fcfe0 Mon Sep 17 00:00:00 2001 From: Boris DuĊĦek Date: Fri, 2 Aug 2013 00:20:57 +0200 Subject: Use NSAccessibilityActionDescription for action descriptions Change-Id: I26a233e72274be7afc2e3e41e13a6743f75e695f Reviewed-on: https://gerrit.libreoffice.org/5238 Reviewed-by: Norbert Thiebaud Tested-by: Norbert Thiebaud --- vcl/aqua/source/a11y/aqua11ywrapper.mm | 23 +---------------------- 1 file changed, 1 insertion(+), 22 deletions(-) (limited to 'vcl/aqua') diff --git a/vcl/aqua/source/a11y/aqua11ywrapper.mm b/vcl/aqua/source/a11y/aqua11ywrapper.mm index 82163ae7c528..47ca292fe3a3 100644 --- a/vcl/aqua/source/a11y/aqua11ywrapper.mm +++ b/vcl/aqua/source/a11y/aqua11ywrapper.mm @@ -905,30 +905,9 @@ static std::ostream &operator<<(std::ostream &s, NSPoint point) { return self; } -// TODO: hard-coded like the role descriptions. is there a better way? -(NSString *)accessibilityActionDescription:(NSString *)action { AX_SAL_DEBUG("[" << self << " accessibilityActionDescription:" << action << "]"); - if ( [ action isEqualToString: NSAccessibilityConfirmAction ] ) { - return @"confirm"; - } else if ( [ action isEqualToString: NSAccessibilityDecrementAction ] ) { - return @"decrement"; - } else if ( [ action isEqualToString: NSAccessibilityDeleteAction ] ) { - return @"delete"; - } else if ( [ action isEqualToString: NSAccessibilityIncrementAction ] ) { - return @"increment"; - } else if ( [ action isEqualToString: NSAccessibilityPickAction ] ) { - return @"pick"; - } else if ( [ action isEqualToString: NSAccessibilityPressAction ] ) { - return @"press"; - } else if ( [ action isEqualToString: NSAccessibilityCancelAction ] ) { - return @"cancel"; - } else if ( [ action isEqualToString: NSAccessibilityRaiseAction ] ) { - return @"raise"; - } else if ( [ action isEqualToString: NSAccessibilityShowMenuAction ] ) { - return @"show menu"; - } else { - return [ NSString string ]; - } + return NSAccessibilityActionDescription(action); } -(AquaA11yWrapper *)actionResponder { -- cgit