HanSolo / SteelSeries-Canvas

The HTML5 Canvas port of the SteelSeries component library. Mainly contains gauges.
120 stars 76 forks source link

timeZoneOffsetHour works strangely #10

Closed draythomp closed 10 years ago

draythomp commented 10 years ago

If I set the time zone offset hour to something other than zero, it doesn't work correctly unless I also change the offset minute. The code is:

        if (timeZoneOffsetHour !== 0 && timeZoneOffsetMinute !== 0) {
            hour = objDate.getUTCHours() + timeZoneOffsetHour;
        } else {
            hour = objDate.getHours();
        }
        hour = hour % 12;

I simply removed the check for offset minute and it works fine now. Similar problem with the offset minute.

mcrossley commented 10 years ago

Thanks, it seems I already had this change in my local copy but I had never committed it :-( I'll get it committed today.

mcrossley commented 10 years ago

Version 0.14.9 uploaded that addresses this issue, can you confirm it is fixed?

draythomp commented 10 years ago

Just tried it out, it worked fine for me. Thanks.