Fix unnecessary overbright modulates used in a few editors
This commit is contained in:
parent
04bf7d4cad
commit
0fa27fd001
@ -570,7 +570,7 @@ void AbstractPolygon2DEditor::forward_canvas_draw_over_viewport(Control *p_overl
|
|||||||
const Vector2 p = (vertex == edited_point) ? edited_point.pos : (points[i] + offset);
|
const Vector2 p = (vertex == edited_point) ? edited_point.pos : (points[i] + offset);
|
||||||
const Vector2 point = xform.xform(p);
|
const Vector2 point = xform.xform(p);
|
||||||
|
|
||||||
const Color overlay_modulate = vertex == active_point ? Color(0.5, 1, 2) : Color(1, 1, 1);
|
const Color overlay_modulate = vertex == active_point ? Color(0.4, 1, 1) : Color(1, 1, 1);
|
||||||
p_overlay->draw_texture(handle, point - handle->get_size() * 0.5, overlay_modulate);
|
p_overlay->draw_texture(handle, point - handle->get_size() * 0.5, overlay_modulate);
|
||||||
|
|
||||||
if (vertex == hover_point) {
|
if (vertex == hover_point) {
|
||||||
|
@ -213,7 +213,7 @@ void GradientTexture2DEdit::_draw() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Draw handles.
|
// Draw handles.
|
||||||
const Color focus_modulate = Color(0.5, 1, 2);
|
const Color focus_modulate = Color(0.4, 1, 1);
|
||||||
bool modulate_handle_from = grabbed == HANDLE_FROM || hovered == HANDLE_FROM;
|
bool modulate_handle_from = grabbed == HANDLE_FROM || hovered == HANDLE_FROM;
|
||||||
bool modulate_handle_to = grabbed == HANDLE_TO || hovered == HANDLE_TO;
|
bool modulate_handle_to = grabbed == HANDLE_TO || hovered == HANDLE_TO;
|
||||||
draw_texture(fill_from_icon, (_get_handle_pos(HANDLE_FROM) - handle_size / 2).round(), modulate_handle_from ? focus_modulate : Color(1, 1, 1));
|
draw_texture(fill_from_icon, (_get_handle_pos(HANDLE_FROM) - handle_size / 2).round(), modulate_handle_from ? focus_modulate : Color(1, 1, 1));
|
||||||
|
@ -237,7 +237,7 @@ void GenericTilePolygonEditor::_base_control_draw() {
|
|||||||
for (int i = 0; i < (int)polygons.size(); i++) {
|
for (int i = 0; i < (int)polygons.size(); i++) {
|
||||||
const Vector<Vector2> &polygon = polygons[i];
|
const Vector<Vector2> &polygon = polygons[i];
|
||||||
for (int j = 0; j < polygon.size(); j++) {
|
for (int j = 0; j < polygon.size(); j++) {
|
||||||
const Color poly_modulate = (tinted_polygon_index == i && tinted_point_index == j) ? Color(0.5, 1, 2) : Color(1, 1, 1);
|
const Color poly_modulate = (tinted_polygon_index == i && tinted_point_index == j) ? Color(0.4, 1, 1) : Color(1, 1, 1);
|
||||||
base_control->draw_texture(handle, xform.xform(polygon[j]) - handle->get_size() / 2, poly_modulate);
|
base_control->draw_texture(handle, xform.xform(polygon[j]) - handle->get_size() / 2, poly_modulate);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -253,7 +253,7 @@ void GenericTilePolygonEditor::_base_control_draw() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (drag_type == DRAG_TYPE_CREATE_POINT) {
|
if (drag_type == DRAG_TYPE_CREATE_POINT) {
|
||||||
base_control->draw_texture(handle, xform.xform(in_creation_point) - handle->get_size() / 2, Color(0.5, 1, 2));
|
base_control->draw_texture(handle, xform.xform(in_creation_point) - handle->get_size() / 2, Color(0.4, 1, 1));
|
||||||
}
|
}
|
||||||
|
|
||||||
// Draw the point creation preview in edit mode.
|
// Draw the point creation preview in edit mode.
|
||||||
|
Loading…
Reference in New Issue
Block a user