瀏覽代碼

Add no-change check to Label3D

Markus Stephanides 1 年之前
父節點
當前提交
c14b395c78
共有 1 個文件被更改,包括 4 次插入0 次删除
  1. 4 0
      scene/3d/label_3d.cpp

+ 4 - 0
scene/3d/label_3d.cpp

@@ -636,6 +636,10 @@ void Label3D::_shape() {
 }
 
 void Label3D::set_text(const String &p_string) {
+	if (text == p_string) {
+		return;
+	}
+
 	text = p_string;
 	xl_text = atr(p_string);
 	dirty_text = true;