parent
35650227cf
commit
e79494c43c
1
NEWS
1
NEWS
|
@ -9,6 +9,7 @@ Bug fixes
|
||||||
- [web] fixed display of Bcc header (#4642)
|
- [web] fixed display of Bcc header (#4642)
|
||||||
- [web] fixed refresh of drafts folder when saving a draft
|
- [web] fixed refresh of drafts folder when saving a draft
|
||||||
- [web] fixed CAS session timeout handling during XHR requests (#4468)
|
- [web] fixed CAS session timeout handling during XHR requests (#4468)
|
||||||
|
- [web] reflect active locale in HTML lang attribute (#4660)
|
||||||
- [core] ignore transparent events in time conflict validation (#4539)
|
- [core] ignore transparent events in time conflict validation (#4539)
|
||||||
- [core] fixed yearly recurrence calculator when starting from previous year
|
- [core] fixed yearly recurrence calculator when starting from previous year
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
Copyright (C) 2007-2016 Inverse inc.
|
Copyright (C) 2007-2019 Inverse inc.
|
||||||
|
|
||||||
This file is part of SOGo
|
This file is part of SOGo
|
||||||
|
|
||||||
|
@ -108,6 +108,7 @@
|
||||||
|
|
||||||
/* locale */
|
/* locale */
|
||||||
- (NSDictionary *)locale;
|
- (NSDictionary *)locale;
|
||||||
|
- (NSString *) localeCode;
|
||||||
|
|
||||||
/* cached resource filenames */
|
/* cached resource filenames */
|
||||||
- (WOResourceManager *) pageResourceManager;
|
- (WOResourceManager *) pageResourceManager;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
Copyright (C) 2007-2016 Inverse inc.
|
Copyright (C) 2007-2019 Inverse inc.
|
||||||
|
|
||||||
This file is part of SOGo
|
This file is part of SOGo
|
||||||
|
|
||||||
|
@ -141,8 +141,6 @@ static SoProduct *commonProduct = nil;
|
||||||
|
|
||||||
- (id) init
|
- (id) init
|
||||||
{
|
{
|
||||||
NSString *language;
|
|
||||||
|
|
||||||
if ((self = [super init]))
|
if ((self = [super init]))
|
||||||
{
|
{
|
||||||
_selectedDate = nil;
|
_selectedDate = nil;
|
||||||
|
@ -150,10 +148,9 @@ static SoProduct *commonProduct = nil;
|
||||||
ASSIGN (userDefaults, [[context activeUser] userDefaults]);
|
ASSIGN (userDefaults, [[context activeUser] userDefaults]);
|
||||||
if (!userDefaults)
|
if (!userDefaults)
|
||||||
ASSIGN (userDefaults, [SOGoSystemDefaults sharedSystemDefaults]);
|
ASSIGN (userDefaults, [SOGoSystemDefaults sharedSystemDefaults]);
|
||||||
language = [userDefaults language];
|
|
||||||
ASSIGN (languages, [context resourceLookupLanguages]);
|
ASSIGN (languages, [context resourceLookupLanguages]);
|
||||||
ASSIGN (locale,
|
ASSIGN (locale,
|
||||||
[[self resourceManager] localeForLanguageNamed: language]);
|
[[self resourceManager] localeForLanguageNamed: [languages objectAtIndex: 0]]);
|
||||||
}
|
}
|
||||||
|
|
||||||
return self;
|
return self;
|
||||||
|
@ -639,6 +636,20 @@ static SoProduct *commonProduct = nil;
|
||||||
return [context valueForKey: @"locale"];
|
return [context valueForKey: @"locale"];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
- (NSString *) localeCode
|
||||||
|
{
|
||||||
|
// WARNING : NSLocaleCode is not defined in <Foundation/NSUserDefaults.h>
|
||||||
|
// Region subtag must be separated by a dash
|
||||||
|
NSMutableString *s = [NSMutableString stringWithString: [locale objectForKey: @"NSLocaleCode"]];
|
||||||
|
|
||||||
|
[s replaceOccurrencesOfString: @"_"
|
||||||
|
withString: @"-"
|
||||||
|
options: 0
|
||||||
|
range: NSMakeRange(0, [s length])];
|
||||||
|
|
||||||
|
return s;
|
||||||
|
}
|
||||||
|
|
||||||
- (WOResourceManager *) pageResourceManager
|
- (WOResourceManager *) pageResourceManager
|
||||||
{
|
{
|
||||||
WOResourceManager *rm;
|
WOResourceManager *rm;
|
||||||
|
|
|
@ -79,20 +79,6 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
- (NSString *) localeCode
|
|
||||||
{
|
|
||||||
// WARNING : NSLocaleCode is not defined in <Foundation/NSUserDefaults.h>
|
|
||||||
// Region subtag must be separated by a dash
|
|
||||||
NSMutableString *s = [NSMutableString stringWithString: [locale objectForKey: @"NSLocaleCode"]];
|
|
||||||
|
|
||||||
[s replaceOccurrencesOfString: @"_"
|
|
||||||
withString: @"-"
|
|
||||||
options: 0
|
|
||||||
range: NSMakeRange(0, [s length])];
|
|
||||||
|
|
||||||
return s;
|
|
||||||
}
|
|
||||||
|
|
||||||
- (NSArray *) monthMenuItems
|
- (NSArray *) monthMenuItems
|
||||||
{
|
{
|
||||||
static NSMutableArray *monthMenuItems = nil;
|
static NSMutableArray *monthMenuItems = nil;
|
||||||
|
|
|
@ -11,7 +11,7 @@
|
||||||
|
|
||||||
<var:string var:value="doctype" const:escapeHTML="NO" />
|
<var:string var:value="doctype" const:escapeHTML="NO" />
|
||||||
<var:if condition="hideFrame" const:negate="YES">
|
<var:if condition="hideFrame" const:negate="YES">
|
||||||
<html const:xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" const:lang="en">
|
<html const:xmlns="http://www.w3.org/1999/xhtml" var:lang="localeCode">
|
||||||
<head>
|
<head>
|
||||||
<title var:sg-default="title"><var:string value="title"/></title>
|
<title var:sg-default="title"><var:string value="title"/></title>
|
||||||
<meta name="hideFrame" var:content="hideFrame" />
|
<meta name="hideFrame" var:content="hideFrame" />
|
||||||
|
|
Loading…
Reference in New Issue