mirror of
https://github.com/inverse-inc/sogo.git
synced 2026-07-06 17:05:10 +00:00
merge of '6418d36640f538c1fb05b31bb43b1a778ad3c093'
and 'eae8192649cef1bdd72533a053dc0aef3baca4e7' Monotone-Parent: 6418d36640f538c1fb05b31bb43b1a778ad3c093 Monotone-Parent: eae8192649cef1bdd72533a053dc0aef3baca4e7 Monotone-Revision: d880f3f750251d35b56db7d720ccacbdeead7540 Monotone-Author: flachapelle@inverse.ca Monotone-Date: 2012-01-31T21:53:10
This commit is contained in:
@@ -1,3 +1,9 @@
|
||||
2012-01-31 Francis Lachapelle <flachapelle@inverse.ca>
|
||||
|
||||
* SoObjects/SOGo/WOResourceManager+SOGo.m
|
||||
(-pathToLocaleForLanguageNamed:): if the language has a CamelCase
|
||||
form, add the first part to the lookup languages.
|
||||
|
||||
2012-01-30 Francis Lachapelle <flachapelle@inverse.ca>
|
||||
|
||||
* UI/WebServerResources/UIxCalUserRightsEditor.js (onUpdateACL):
|
||||
|
||||
+1
-1
@@ -509,9 +509,9 @@ static BOOL debugLeaks;
|
||||
}
|
||||
|
||||
if (!locale)
|
||||
// no appropriate language, fallback to default
|
||||
locale = [[self resourceManager] localeForLanguageNamed: @"English"];
|
||||
|
||||
/* no appropriate language, fallback to default */
|
||||
return locale;
|
||||
}
|
||||
|
||||
|
||||
@@ -20,6 +20,7 @@
|
||||
* Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
|
||||
#import <Foundation/NSCharacterSet.h>
|
||||
#import <Foundation/NSData.h>
|
||||
#import <Foundation/NSDictionary.h>
|
||||
|
||||
@@ -33,12 +34,21 @@
|
||||
{
|
||||
static Class MainProduct = Nil;
|
||||
NSString *lpath;
|
||||
NSRange range;
|
||||
NSMutableArray *languages;
|
||||
|
||||
#warning TODO: create method "languagesBeginingWith:"
|
||||
languages = [NSMutableArray arrayWithObject: _name];
|
||||
|
||||
// If the language has a CamelCase form, add the first part to the lookup languages.
|
||||
range = [_name rangeOfCharacterFromSet: [NSCharacterSet uppercaseLetterCharacterSet]
|
||||
options: NSBackwardsSearch
|
||||
range: NSMakeRange(1, [_name length] - 1)];
|
||||
if (range.location != NSNotFound && range.location > 0)
|
||||
[languages addObject: [_name substringToIndex: range.location]];
|
||||
|
||||
lpath = [self pathForResourceNamed: @"Locale"
|
||||
inFramework: nil
|
||||
languages: [NSArray arrayWithObject:_name]];
|
||||
languages: languages];
|
||||
if (![lpath length])
|
||||
{
|
||||
if (!MainProduct)
|
||||
|
||||
Reference in New Issue
Block a user