mirror of
https://github.com/tonytins/CozyPixelStudio.git
synced 2025-12-16 03:44:42 -05:00
Use enums instead of strings for tools
This could be a slight increase in performance
This commit is contained in:
parent
bda9e6267d
commit
5b7d161ecf
6 changed files with 71 additions and 72 deletions
|
|
@ -17,7 +17,7 @@ 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
|
||||
if Global.current_left_tool == "Pencil":
|
||||
if Global.current_left_tool == Global.Tools.PENCIL:
|
||||
Global.left_color_interpolation_container.visible = true
|
||||
# if hint_tooltip == "":
|
||||
# Global.left_brush_type_label.text = tr("Custom brush")
|
||||
|
|
@ -40,7 +40,7 @@ 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:
|
||||
if Global.current_right_tool == "Pencil":
|
||||
if Global.current_right_tool == Global.Tools.PENCIL:
|
||||
Global.right_color_interpolation_container.visible = true
|
||||
# if hint_tooltip == "":
|
||||
# Global.right_brush_type_label.text = tr("Custom brush")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue