Message loop for TAB management