Improve behavior of pinning to tab.