Improved generation.
- delegates
- better naming
- comment to reflect real signature for callbacks.