have function must pass delegate.

2014-11-13 Thread Spacen Jasset via Digitalmars-d-learn
A method call in the GTK API takes a delegate as an 
argument(addOnActivate) I would like to be able to pass a 
function instead (address of). What is the solution, at present I 
have a wrapper class around the function.


Re: have function must pass delegate.

2014-11-13 Thread ketmar via Digitalmars-d-learn
On Thu, 13 Nov 2014 14:02:22 +
Spacen Jasset via Digitalmars-d-learn
 wrote:

> A method call in the GTK API takes a delegate as an 
> argument(addOnActivate) I would like to be able to pass a 
> function instead (address of). What is the solution, at present I 
> have a wrapper class around the function.
std.functional has `toDelegate`.


signature.asc
Description: PGP signature