Rework callbacks

Now every function which accepts kwargs is allowed as an on_click
callback.