add open/close callbacks, fix issue with tabs on Android