[TIMOB-2858] Android: Ti.UI.PICKER_TYPE_TIME not checking timezone
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | Medium |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2011-04-17T02:00:16.000+0000 |
Affected Version/s | n/a |
Fix Version/s | Release 1.6.0 M06 |
Components | Android |
Labels | android, date, defect, enterprise, picker, release-1.5.2, release-1.6.0, reported-1.5.1, rplist |
Reporter | Alan Leard |
Assignee | Don Thorp |
Created | 2011-04-15T03:31:20.000+0000 |
Updated | 2011-04-17T02:00:16.000+0000 |
Description
Ticket Reference: http://developer.appcelerator.com/helpdesk/view/66871">http://developer.appcelerator.com/helpdesk/view/66871
Using the Picker widget with the useSpinner flag set to true, the system ignores the users timezone and displays GMT.
var d = new Date();
Ti.API.error("The date is: " + d);
//[ERROR] [942,1315] The date is: Mon Jan 17 2011 15:09:31 GMT-0800 (PST)
var timePicker = Ti.UI.createPicker({
type: Ti.UI.PICKER_TYPE_TIME,
useSpinner:true,
value:d
});
win.add(timePicker);
win.open();
This bug affects all UI widgets that can receive their value property as a date object so at least four widgets are affected, can we bump up the priority to high? Also, I have submitted a pull request for the fix: https://github.com/appcelerator/titanium_mobile/pull/60">https://github.com/appcelerator/titanium_mobile/pull/60
(from [20640931bf29aada4f66a0152c57ad102db12211]) [#2858 state:fixed-in-qa] adjust TiConvert.toJSONString so it properly puts the string representation of the date in UTC rather than local https://github.com/appcelerator/titanium_mobile/commit/20640931bf29aada4f66a0152c57ad102db12211"> https://github.com/appcelerator/titanium_mobile/commit/20640931bf29...
(from [84c6ea58ceae9dc0f52d909548db7352ab8368f5]) [#2858 state:fixed-in-qa] adjust TiConvert.toJSONString so it properly puts the string representation of the date in UTC rather than local https://github.com/appcelerator/titanium_mobile/commit/84c6ea58ceae9dc0f52d909548db7352ab8368f5"> https://github.com/appcelerator/titanium_mobile/commit/84c6ea58ceae...
verified on Nexus S / 2.3.2