On 9/20/2013 3:12 PM, Philipp Kewisch wrote:
What about JS_NewDateObject, JS_NewDateObjectMsec, JS_ObjectIsDate,
js_DateIsValid? Most of these are in jsapi.h, and we need it in
Lightning for this code:
http://mxr.mozilla.org/comm-central/source/calendar/base/backend/libical/calDateTime.cpp#597
We are not quite ready to get rid of the libical backend right now, so
removing these functions without replacement will cause some
complications for Lightning.
Not knowing this code well, it seems that this code takes a double and
converts it to a JS date object with some timezone conversion. It seems
to me that you could write this code entirely in JS and just pass around
the integer or double values using IDL, to avoid the JSAPI usage
altogether. That might involve always replacing calDateTime with a
JS-implemented wrapper, but that's the kind of technique that we need to
be encouraging in general.
Is that technique a usable workaround for raw JSAPI usage?
--BDS
_______________________________________________
dev-platform mailing list
dev-platform@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-platform