mirror of
https://codeberg.org/Freeyourgadget/Gadgetbridge
synced 2025-01-27 01:57:32 +01:00
try to parse timezone that comes back from huami devices
(there are other places where something like this has to be done, probably also in the other direction) related to #869 (cherry picked from commit a58e3f66ce2320d2a850af5e3579d3ef4a0ef989)
This commit is contained in:
parent
6b56e8e568
commit
9764e8e54e
@ -144,6 +144,12 @@ public class BLETypeConversions {
|
|||||||
value[6] & 0xff
|
value[6] & 0xff
|
||||||
);
|
);
|
||||||
|
|
||||||
|
if (value.length > 7) {
|
||||||
|
TimeZone timeZone = TimeZone.getDefault();
|
||||||
|
timeZone.setRawOffset(value[7] * 15 * 60 * 1000);
|
||||||
|
timestamp.setTimeZone(timeZone);
|
||||||
|
}
|
||||||
|
|
||||||
if (honorDeviceTimeOffset) {
|
if (honorDeviceTimeOffset) {
|
||||||
int offsetInHours = MiBandCoordinator.getDeviceTimeOffsetHours();
|
int offsetInHours = MiBandCoordinator.getDeviceTimeOffsetHours();
|
||||||
if (offsetInHours != 0) {
|
if (offsetInHours != 0) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user