Poison-ui

A cross-platform desktop/mobile UI engine written in D using dsfml

View project on GitHub

Dub version

poison.core.action

Source

Module for actions. Actions are classes that wraps around a function pointer or delegate.

Authors:

  Jacob Jensen

License:

  https://github.com/PoisonEngine/poison-ui/blob/master/LICENSE

public:





public class Action


        public:



An action.


public this(void function() f);


Creates a new instance of the action passing a function pointer.

Parameters:

fThe function pointer.

public this(void delegate() d);


Creates a new instance of the action passing a delegate.

Parameters:

dThe delegate.

public void opCall();


Operator overload for calling Action implicit.


public class ActionArgs(T)


        public:



An action that takes a generic argument.


public this(void function(T) f);


Creates a new instance of the action passing a function pointer.

Parameters:

fThe function pointer.

public this(void delegate(T) d);


Creates a new instance of the action passing a delegate.

Parameters:

dThe delegate.

public void opCall(T arg);


Operator overload for calling Action implicit.

Parameters:

argThe argument to pass.

Generated by venom - Poison Engine's Documentation Generator