Skip to content

Commit bc530e5

Browse files
committed
fix gradient edit picker position
1 parent 9578fb2 commit bc530e5

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

material_maker/widgets/gradient_editor/gradient_edit.gd

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -138,10 +138,12 @@ func select_color(cursor:GradientEditCursor) -> void:
138138
color_picker_popup.min_size = color_picker_popup.get_contents_minimum_size() * content_scale_factor
139139

140140
var _scale := get_global_transform().get_scale()
141-
141+
142142
color_picker_popup.position.x = (global_position.x + size.x*_scale.x) * content_scale_factor
143143
color_picker_popup.position.y = global_position.y * content_scale_factor
144-
color_picker_popup.position += get_window().position
144+
145+
if not get_tree().root.gui_embed_subwindows:
146+
color_picker_popup.position += get_window().position
145147

146148
color_picker_popup.popup_hide.connect(color_picker_popup.queue_free)
147149
color_picker_popup.popup_hide.connect(set.bind("mode", Modes.IDLE))

0 commit comments

Comments
 (0)