Inactivate active tab when hiding tabs

Issue #59