boolean (@NotNull IdeFrameImpl frame, @NotNull CoroutineScope coroutineScope) { boolean allowed = isAllowedFrame(frame) && JdkEx.setTabbingMode(frame, getWindowId(), () -> updateTabBars(null)); if (allowed) { Foundation.invoke("NSWindow", "setAllowsAutomaticWindowTabbing:", true); executeOnCancelInEdt(coroutineScope, () -> { updateTabBars(null); return Unit.INSTANCE; }); } return allowed; }