mirror of
https://github.com/Orama-Interactive/Pixelorama.git
synced 2025-01-18 09:09:47 +00:00
Set Selection.gd process input false by default, fix cursor still being set to a cross when entering the canvas if it's disabled in the preferences
This commit is contained in:
parent
6a7e060f73
commit
5dfe1cc271
|
@ -416,13 +416,7 @@ var native_cursors := false:
|
|||
else:
|
||||
control.set_custom_cursor()
|
||||
## Found in Preferences. If [code]true[/code], cursor becomes cross shaped when hovering the canvas.
|
||||
var cross_cursor := true:
|
||||
set(value):
|
||||
cross_cursor = value
|
||||
if cross_cursor:
|
||||
main_viewport.mouse_default_cursor_shape = Control.CURSOR_CROSS
|
||||
else:
|
||||
main_viewport.mouse_default_cursor_shape = Control.CURSOR_ARROW
|
||||
var cross_cursor := true
|
||||
|
||||
# View menu options
|
||||
## If [code]true[/code], the canvas is in greyscale.
|
||||
|
|
|
@ -80,6 +80,8 @@ class Gizmo:
|
|||
|
||||
|
||||
func _ready() -> void:
|
||||
# It's being set to true only when the big_bounding_rectangle has a size larger than 0
|
||||
set_process_input(false)
|
||||
Global.camera.zoom_changed.connect(_update_on_zoom)
|
||||
gizmos.append(Gizmo.new(Gizmo.Type.SCALE, Vector2i(-1, -1))) # Top left
|
||||
gizmos.append(Gizmo.new(Gizmo.Type.SCALE, Vector2i(0, -1))) # Center top
|
||||
|
|
|
@ -14,7 +14,8 @@ func _on_ViewportContainer_mouse_entered() -> void:
|
|||
camera.set_process_input(true)
|
||||
Global.control.left_cursor.visible = Global.show_left_tool_icon
|
||||
Global.control.right_cursor.visible = Global.show_right_tool_icon
|
||||
Input.set_default_cursor_shape(Input.CURSOR_CROSS)
|
||||
if Global.cross_cursor:
|
||||
Input.set_default_cursor_shape(Input.CURSOR_CROSS)
|
||||
|
||||
|
||||
func _on_ViewportContainer_mouse_exited() -> void:
|
||||
|
|
Loading…
Reference in a new issue