- From: Cameron McCormack <cam@mcc.id.au>
- Date: Mon, 09 Apr 2012 12:49:42 +1000
- To: Boris Zbarsky <bzbarsky@MIT.EDU>
- CC: Kenneth Russell <kbr@google.com>, Glenn Maynard <glenn@zewt.org>, public_webgl@khronos.org, "public-script-coord@w3.org" <public-script-coord@w3.org>
Cameron McCormack: >> Would a DOM object be able to create and return its own objects that >> implement callback interfaces? Boris Zbarsky: > I'm not sure what you mean. For one thing, it's not really quite > defined what it means to "implement a callback interface"... Any JS non-platform object can serve as a callback interface object. So perhaps with callback interface A { attribute long x; attribute long y; void f(); }; interface B { A g(); }; calling B.g() could return a new JS native object with "x", "y" and "f" properties. The same question arises with callback functions. If you defined callback SomeCallback = void (); interface C { attribute SomeCallback handler; }; should C.handler be allowed to return a Function object that script didn't create? Maybe.
Received on Monday, 9 April 2012 02:50:19 UTC