[Bug 5814] WebIDL: Resolve the callback issue

http://www.w3.org/Bugs/Public/show_bug.cgi?id=5814





--- Comment #4 from Cameron McCormack <cam@mcc.id.au>  2008-11-25 00:23:42 ---
(In reply to comment #3)
> I guess I can live with that, but it still seems heavy-duty to me.

It's really only heavy duty in the sense that it takes a few more characters to
type.

> I'd prefer something like:
> 
>   callback TimeoutHandler ([Variadic] in any args);
> 
> ...at the top level, i.e. introducing a new type, followed by just using it as
> if it was a defined type.

I've been reluctant so far to introduce features that are syntactically
incompatible with OMG IDL.

> I don't mind it being turned into an interface for languages that have no
> function types, but it is first and foremost a callback, not an interface,
> IMHO.

It's an interface that user code needs to implement to be called back, no? :)

> The { handleEvent: function() ... } thing seems like an accident to me, not
> something we should encourage.

But that is how DataGridProvider is expected to be implemented.  I'd prefer
that regardless of the number of operations on a callback interface it be
implementable using properties, for consistency.


-- 
Configure bugmail: http://www.w3.org/Bugs/Public/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.

Received on Tuesday, 25 November 2008 00:23:52 UTC