浏览代码

Fixed segfault when hovering over scene tree elements and showing tooltips.

Wilson E. Alvarez 8 年之前
父节点
当前提交
0017e21521
共有 1 个文件被更改,包括 4 次插入0 次删除
  1. 4 0
      scene/main/viewport.cpp

+ 4 - 0
scene/main/viewport.cpp

@@ -1456,6 +1456,10 @@ void Viewport::_gui_show_tooltip() {
 		gui.tooltip_popup = NULL;
 	}
 
+	if (!gui.tooltip) {
+		return;
+	}
+
 	Control *rp = gui.tooltip->get_root_parent_control();
 	if (!rp)
 		return;