Added a tab activation callback

Hi Samson, i've added a callback event which is triggered when a tab is selected.