1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-24 15:26:15 +00:00

Fix ColorPicker to use theme constants

This commit is contained in:
Poommetee Ketson
2017-07-04 05:52:45 +07:00
parent f36cd77feb
commit 668d00ff2d
6 changed files with 33 additions and 34 deletions

View File

@@ -61,10 +61,8 @@ int GradientEdit::_get_point_from_pos(int x) {
void GradientEdit::_show_color_picker() {
if (grabbed == -1)
return;
Size2 ms = Size2(350, picker->get_combined_minimum_size().height + 10);
picker->set_pick_color(points[grabbed].color);
popup->set_position(get_global_position() - Vector2(ms.width - get_size().width, ms.height));
popup->set_size(ms);
popup->set_position(get_global_position() - popup->get_combined_minimum_size());
popup->popup();
}