mirror of
https://github.com/tonytins/CozyPixelStudio.git
synced 2025-07-14 23:04:43 -04:00
Having no active selection no longer treats all the pixels of the canvas as selected
A performance boost for when opening large images. Also fixed an issue with pixels being selected outside of the canvas boundaries, when the selection rectangle was outside the canvas and its size got reduced.
This commit is contained in:
parent
7f1594e1bc
commit
c54b74f829
9 changed files with 31 additions and 19 deletions
|
@ -39,7 +39,7 @@ func set_rect(rect : Rect2) -> void:
|
|||
|
||||
var project : Project = Global.current_project
|
||||
if rect.has_no_area():
|
||||
project.select_all_pixels()
|
||||
project.selected_pixels = []
|
||||
else:
|
||||
project.clear_selection()
|
||||
for x in range(rect.position.x, rect.end.x):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue