fixed up tab tracking so closed pages are removed from buffer and can be reopened