fix(calendar(js)): adjust line of the current time to user's timezone

Fixes #5512
This commit is contained in:
Francis Lachapelle
2022-05-02 12:37:58 -04:00
parent 700d726511
commit 1b3b9c253c
2 changed files with 21 additions and 12 deletions
+5 -1
View File
@@ -1,6 +1,6 @@
/* UIxJSONPreferences.m - this file is part of SOGo
*
* Copyright (C) 2007-2021 Inverse inc.
* Copyright (C) 2007-2022 Inverse inc.
*
* This file is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -19,6 +19,7 @@
*/
#import <Foundation/NSDictionary.h>
#import <Foundation/NSTimeZone.h>
#import <Foundation/NSValue.h>
#import <NGObjWeb/SoObjects.h>
@@ -402,6 +403,9 @@ static SoProduct *preferencesProduct = nil;
[locale objectForKey: @"NSShortWeekDayNameArray"], @"shortDays",
nil] forKey: @"locale"];
// Add timezone offset
[values setObject: [NSNumber numberWithInt: [[defaults timeZone] secondsFromGMT]] forKey: @"UserTimeZoneSecondsFromGMT"];
accounts = [NSMutableArray arrayWithArray: [values objectForKey: @"AuxiliaryMailAccounts"]];
if ([accounts count])
{