浏览代码

colorpicker margin bug fixed

(cherry picked from commit 9d224ac42920728031ac389dfc11f7fa9e190176)
Thakee Nathees 5 年之前
父节点
当前提交
25ed0d4366
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      scene/gui/color_picker.cpp

+ 1 - 1
scene/gui/color_picker.cpp

@@ -70,7 +70,7 @@ void ColorPicker::_notification(int p_what) {
 		case NOTIFICATION_PARENTED: {
 
 			for (int i = 0; i < 4; i++)
-				set_margin((Margin)i, get_constant("margin"));
+				set_margin((Margin)i, get_margin((Margin)i) + get_constant("margin"));
 		} break;
 		case NOTIFICATION_VISIBILITY_CHANGED: {