Fixed exception when canceling Add Tab dialog. (Issue #81)