Commit Graph

7750 Commits

Author SHA1 Message Date
David Capello
9c319e46ac Fix bug transforming the same linked cel two times
As we wanted the current cel as the first cel to transform (to avoid
re-transforming it with inner cmds when we drop pixels), if this cel
was a linked from other one it will not be removed from the
getEditableCels() list, so two linked cels would appear two times in
the list. Now we remove the current cel correctly when it's a linked
cel after re-adding it.

Reported here: https://community.aseprite.org/t/8618
2021-04-07 18:32:56 -03:00
David Capello
67eeac8045 Fix bug keeping the modified range different than the visible range when moving pixels
When we clicked the current cel/frame/layer on MovingPixelsState in
the Timeline, we weren't dropping the pixels, so the range was
different in the Timeline UI, but we were using the old site range
which was different (bigger) than the Timeline range.

Fixes several bugs: https://community.aseprite.org/t/8618
2021-04-07 18:11:30 -03:00
David Capello
169cfa39cf Use timeline selection only when it's visible 2021-04-07 15:20:36 -03:00
David Capello
a122f1ceba Reset tool preferences just once when running from CLI 2021-04-07 12:58:03 -03:00
David Capello
351900b4e7 Update flic and tga modules 2021-04-07 11:24:39 -03:00
Martín Capello
783802a980 Fix eyedropper when picking tiles from composed image
When eyedropper was used to pick tiles from a composed image having an
image layer and a tilemap layer without cels, it tried to pick tiles
from the image layer.
2021-04-06 19:22:04 -03:00
Martín Capello
079f7b6537 Fix the mouse cursor shown when entering to submenus 2021-04-05 14:31:53 -03:00
Martín Capello
fdbb3aec59 Fix alert when installing an extension
Before this, the alert's parent window was the main window instead of
the options window.
2021-04-05 14:31:48 -03:00
Gaspar Capello
5e172d81ee Fix exception during palette changes while editor state is MovingPixelsState
Before this fix a console error appeared during a setTransparentIndex
or setPalette execution (or other functions in the ColorBar class)
while some selected portion of the image was
transformed (MovingPixelsState).

Bug reported: https://community.aseprite.org/t/5288
2021-03-31 17:29:24 -03:00
David Capello
27273e5529 Fix mouse pos of the new message created in Widget::offerCapture() 2021-03-31 17:14:31 -03:00
David Capello
4f4f5fee7f Fix tooltips in multi-displays mode when the Preview window is open 2021-03-31 17:10:31 -03:00
David Capello
ff3b14978a Comment ASSERT() that can happen in ButtonSet 2021-03-31 15:34:11 -03:00
Martín Capello
b35cf6c66d Add .vs directory to .gitignore 2021-03-29 16:34:53 -03:00
Martín Capello
734d3bace6 Fix regression: problems in the preferences and theme selection
The mouse cursor dissapears when "Apply" button is pressed or when a
new window appers.
2021-03-29 16:33:47 -03:00
David Capello
0396e80fce Fix popup menu positions when we are not in the main screen 2021-03-29 15:55:56 -03:00
David Capello
dead710213 Fix regression showing the selection feedback above all layers
Without this fix we'll see the selection stroke feedback in the same
level as the active layer. With this patch the preview is displayed at
the top just as in the main branch.
2021-03-29 12:34:19 -03:00
David Capello
9be9b4d5e5 Merge branch 'main' into beta 2021-03-26 12:19:45 -03:00
David Capello
a5c36d0b0f Add possibility to cancel the DrawingState with Undo/Redo/Cancel commands
To match the new MovingCelState behavior.
2021-03-26 12:05:28 -03:00
David Capello
768b69113a Disconnect from BeforeCommandExecution signal onBeforePopState to avoid double backToPreviousState() calls
In some special cases (several key press enqueued?) we can receive a
BeforeCommandExecution signal when we are not part of the Editor state
stack anymore.

Related to 5ba8cecdde
2021-03-26 11:40:10 -03:00
David Capello
5ba8cecdde Fix a crash pressing (and keeping pressed) Ctrl+Z (Command+Z)
This tries to avoid calling onBeforeCommandExecution() after we are
going to the previous state. This might be a problem on all states
that are using a scoped_connection to disconnect from the app::Context
signal in the destructor (instead of in the
onBeforePopState). Something to fix next for all other states.
2021-03-26 10:45:46 -03:00
Gaspar Capello
42201a4783 Fix bug while moving an image in MovingCelState
Original post: https://community.aseprite.org/t/pretty-nasty-bug-specific/8290

Before this fix, if you pressed Cmd Z / Ctrl Z (undo) while moving an image holding Cmd/Ctrl key,
the moved image were gettting stuck on cursor, and console errors were shown on every click.
2021-03-26 10:01:11 -03:00
David Capello
726065164f Fix copying irregular areas of tiles in "tiles mode"
Now we can use the lasso tool in tiles mode, select an
irregular (non-rectangular) area and move that area of tiles
correctly.
2021-03-22 20:20:20 -03:00
David Capello
5cd66b58f1 Fix correct hot region for dynamics dialog 2021-03-22 11:56:02 -03:00
David Capello
103a8087cc Fix bug selecting brush types and dynamics with one click + dragging mouse
Fixed bug offering mouse capture to widgets in other displays when
get_multiple_displays() is on.
2021-03-22 11:54:57 -03:00
David Capello
a9640a28dc Fix several bugs handling the clipboard on X11 2021-03-22 11:27:59 -03:00
David Capello
cf21f78d8d Limit loaded windows frame position with active workarea 2021-03-19 20:20:24 -03:00
David Capello
d93fdfd49e Fix indentation of if statement 2021-03-19 19:32:28 -03:00
David Capello
b015b16da5 Merge branch 'main' into beta 2021-03-19 19:27:29 -03:00
David Capello
bcd69495ce Fix several issues locating windows with multiple UI windows
We've refactored the code to support locating windows (and popups
windows + hot regions) correctly in both modes: with one ui::Display
and with multiple ui::Displays.

For this we've added a new ui::fit_bounds() function that works in
both modes.
2021-03-19 18:57:56 -03:00
David Capello
ed8446ca0b Run CI on PRs 2021-03-18 10:02:09 -03:00
David Capello
7079801697 Avoid leaks running "gen" when memory sanitizer is enabled 2021-03-15 21:05:33 -03:00
David Capello
6b89075b26 Don't send paint messages when we are closing the app 2021-03-09 16:43:22 -03:00
Gaspar Capello
1193bf18fc Fix lua error crash (fix #2635)
Prevents crashes from uncaught exceptions generated from Lua errors
when running aseprite from the console with -script param.
2021-03-09 16:40:24 -03:00
David Capello
2dccb6d646 Add GitHub actions 2021-03-08 11:38:04 -03:00
David Capello
246b52b086 Update laf module 2021-03-08 11:16:57 -03:00
David Capello
35bb3af6e2 Replace all base::Bind() with lambda functions 2021-03-05 20:09:42 -03:00
David Capello
ddbbf12bfc Update main branch 2021-03-05 18:39:36 -03:00
David Capello
e50ea46c91 Minor change in CMakeLists.txt 2021-03-05 18:27:31 -03:00
David Capello
9189b8b9dc Fix indentation 2021-03-03 10:49:04 -03:00
David Capello
777a0f132a Don't send paint messages when we are closing the app 2021-03-03 09:54:20 -03:00
David Capello
d7e154b726 Update laf module 2021-03-02 14:29:30 -03:00
David Capello
8034b0cbcc Add support for multiple native windows (#139, #250, #962, etc.)
Each ui::Window now can have a related native os::Window. This
connection is done through the ui::Display class added recently in
c3d52f0bbe.
2021-03-02 13:50:49 -03:00
David Capello
74961f58c0 Missing std::cout -> TRACEARGS from b163b7be48 2021-03-02 12:26:42 -03:00
David Capello
f70e8d3ae7 Add ui::expandWindow() to change the size of a window dynamically 2021-03-02 08:44:35 -03:00
David Capello
b163b7be48 Simplify REPORT_EVENTS code in ui::Manager 2021-02-26 14:08:40 -03:00
David Capello
4a17ab7ef4 Merge branch 'master' into beta 2021-02-26 09:29:50 -03:00
David Capello
5d6aa3ff11 [win] Fix leak of GDI objects (HRGNs) 2021-02-26 09:26:38 -03:00
David Capello
4c9c35bdfd Update laf module 2021-02-25 17:17:29 -03:00
David Capello
49d5787737 Merge branch 'master' into beta 2021-02-25 17:12:53 -03:00
David Capello
ef4f691459 Generate a native cursor for the crosshair on the sprite
In this way we can get pixel from the window surface and put pixels in
the new cursor surface which will represent the crosshair on the
mouse/screen position. In this way we avoid an effect of a slow mouse
response on high refresh rates.

Maybe related to: https://community.aseprite.org/t/3354
2021-02-25 16:56:33 -03:00