Added a way to active tab consistently. Needs to be tweaked though.