Re: accessibilityLanguage in section headers of grouped table view
Re: accessibilityLanguage in section headers of grouped table view
- Subject: Re: accessibilityLanguage in section headers of grouped table view
- From: Matthias Schmitt <email@hidden>
- Date: Mon, 14 May 2012 16:43:40 +0200
Hello,
In my last mail I reported some problems setting the accessibilityLanguage for section headers in UITable objects running with style UITableViewStyleGrouped. VoiceOver was always using the system language to speak the texts, independent from the language set via setAccessibilityLanguage.
On 10.05.2012, at 17:04, Chris Fleizach wrote:
> This is a bug. No way to work around it right now.
I think I found a way to work around it, which I want to share with you.
---------------
#import "NSObject+AccessibilityLanguage.h"
@implementation NSObject (AccessibilityLanguage)
- (NSString *)accessibilityLanguage {
cnlAppDelegate *appDelegate = [[UIApplication sharedApplication] delegate];
if (appDelegate != nil) {
if ([appDelegate prefLanguage] == 0) {
return @"de-DE";
} else {
return @"fr-FR";
}
}
return nil; // this line should never be executed
}
---------------
My appDelegate object is the object, which stores the current language. Overwriting accessibilityLanguage for all objects seems to resolve the problem. I am using this on iOS 5.1.1.
I hope this might be of use for someone out there.
Best regards
Matthias Schmitt
magic moving pixel s.a.
23, Avenue Grande-Duchesse Charlotte
L-3441 Dudelange
Luxembourg
Phone: +352 54 75 75 - 0
http://www.mmp.lu
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Accessibility-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden