Further updates to the new APIs

Note: still using an old API to get the current tab.