瀏覽代碼

Merge pull request #54320 from YeldhamDev/tabbar_close_last_fix

Rémi Verschelde 3 年之前
父節點
當前提交
3e26ad3a5f
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      scene/gui/tab_bar.cpp

+ 1 - 1
scene/gui/tab_bar.cpp

@@ -222,7 +222,7 @@ void TabBar::gui_input(const Ref<InputEvent> &p_event) {
 				}
 			}
 
-			if (max_drawn_tab <= 0) {
+			if (tabs.is_empty()) {
 				// Return early if there are no actual tabs to handle input for.
 				return;
 			}