"Brush color from" now invisible when pixel brush is selected

This commit is contained in:
OverloadedOrama 2019-12-03 00:25:22 +02:00
parent a2fdf7c4a5
commit 5ffd0ecf6a
3 changed files with 49 additions and 32 deletions

View file

@ -9,11 +9,13 @@ func _on_BrushButton_pressed() -> void:
Global.current_left_brush_type = brush_type
Global.custom_left_brush_index = custom_brush_index
if custom_brush_index > -1: #Custom brush
Global.left_color_interpolation_container.visible = true
if hint_tooltip == "":
Global.left_brush_type_label.text = "Custom brush"
else:
Global.left_brush_type_label.text = "Brush: %s" % hint_tooltip
else: #Pixel brush
Global.left_color_interpolation_container.visible = false
Global.left_brush_type_label.text = "Brush: Pixel"
Global.update_left_custom_brush()
@ -22,11 +24,13 @@ func _on_BrushButton_pressed() -> void:
Global.current_right_brush_type = brush_type
Global.custom_right_brush_index = custom_brush_index
if custom_brush_index > -1:
Global.right_color_interpolation_container.visible = true
if hint_tooltip == "":
Global.right_brush_type_label.text = "Custom brush"
else:
Global.right_brush_type_label.text = "Brush: %s" % hint_tooltip
else: #Pixel brush
Global.right_color_interpolation_container.visible = false
Global.right_brush_type_label.text = "Brush: Pixel"
Global.update_right_custom_brush()