Fix launching a new tab when there is no OS window

This commit is contained in:
pagedown 2022-02-07 13:55:43 +08:00
parent a2269cb66e
commit ddfda3efde
No known key found for this signature in database
GPG Key ID: E921CF18AC8FF6EB

View File

@ -1826,6 +1826,8 @@ class Boss:
self._create_tab(list(args), cwd_from=cwd_from) self._create_tab(list(args), cwd_from=cwd_from)
def new_tab_with_wd(self, wd: str) -> None: def new_tab_with_wd(self, wd: str) -> None:
if not self.os_window_map:
self.add_os_window()
special_window = SpecialWindow(None, cwd=wd) special_window = SpecialWindow(None, cwd=wd)
self._new_tab(special_window) self._new_tab(special_window)