From a3481ed1c780ac983d474d97af68f7175f296116 Mon Sep 17 00:00:00 2001 From: Paulb23 Date: Wed, 15 Jun 2016 18:19:34 +0100 Subject: Fixed error: set_current_tab print on project open --- scene/gui/tab_container.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/scene/gui/tab_container.cpp b/scene/gui/tab_container.cpp index d19e5f0d60..ad790d1b54 100644 --- a/scene/gui/tab_container.cpp +++ b/scene/gui/tab_container.cpp @@ -412,8 +412,9 @@ void TabContainer::_notification(int p_what) { } break; case NOTIFICATION_THEME_CHANGED: { - - call_deferred("set_current_tab",get_current_tab()); //wait until all changed theme + if (get_tab_count() > 0) { + call_deferred("set_current_tab",get_current_tab()); //wait until all changed theme + } } break; } } -- cgit v1.2.3