Commit Graph

9551 Commits

Author SHA1 Message Date
David Capello
8fc7592066 Make clang tidy action work in PRs from forks using split_workflow 2024-02-27 19:07:53 -03:00
David Capello
619b5cbada Run clang tidy in the context of the merge commit 2024-02-27 15:41:07 -03:00
David Capello
03403953f3 Fix cmake -B param in clang tidy action 2024-02-27 14:11:02 -03:00
David Capello
351d9c863f Add config_file parameter to clang tidy action 2024-02-27 13:55:43 -03:00
David Capello
be891230da Remove Ninja from clang tidy action 2024-02-27 13:49:32 -03:00
David Capello
f19215ea9d Update laf module 2024-02-27 13:23:04 -03:00
David Capello
7aca017a58 Fix use-after free in ase_ungroup_all()
Anyway this code is not used anymore, it was for v1.1 when v1.1 and
v1.2 branches were developed at the same time (layer groups feature
was added in v1.2, so v1.1 just moved groups children to the root).
2024-02-27 13:20:13 -03:00
David Capello
52afc9e9a7 Use build directory for cmake command on clang tidy
It's required by freetype library as it looks like it doesn't allow to
build in the same source directory.
2024-02-27 12:20:26 -03:00
David Capello
104f80b334 Change job name of clang tidy to avoid confusion with the build process 2024-02-27 12:20:04 -03:00
David Capello
a86b0a7d0c Fix clang_tidy.yml path 2024-02-27 12:07:19 -03:00
David Capello
1d1b25d425 Update laf module 2024-02-27 11:54:11 -03:00
David Capello
924eaddf75 Add clang tidy workflow action 2024-02-27 11:50:07 -03:00
David Capello
908677edbb Update clang-tidy checks 2024-02-27 11:04:03 -03:00
David Capello
b813c1ad5f Fix regression introduced in 9e2728992d
Some info here:
https://github.com/aseprite/aseprite/pull/4299#discussion_r1503955328
2024-02-27 10:45:26 -03:00
Gaspar Capello
9e2728992d Fix slice tool doesn't work correctly in a tilemap layer when we are in Manual mode (fix #4290) 2024-02-27 10:43:44 -03:00
Martín Capello
7b9594f4e0 Avoid moving the playback cue when decrementing a ping-pong tag's repeat field that has only one frame (fix #4336) 2024-02-26 22:07:31 -03:00
David Capello
c64756ebde Keep testing loading/saving properties as they are in userdata_codec.lua 2024-02-26 17:44:56 -03:00
David Capello
9f75260d25 Change userdata_codec.lua test to check pre-saved user data properties 2024-02-26 17:40:15 -03:00
David Capello
e949a5401d Drop selection when we hide a layer that is being transformed (fix #4179, fix #3254)
This fixes several problems in MovingPixelsState where hidden layers
were transformed anyway when we switched the visibility of a layer in
this state.

Other fix was tried before in #3254 but we needed the onBefore/After
layer visibility change notifications to make this work properly
(i.e. drop pixels when the visiblity of a layer is changed).

The only drawback at this moment is that changing the visibility of
the non-active layer when we are transforming multiple cels/timeline
range can be confused because we don't have #2144/#2865 implemented
yet.

This bug was originally reported here: https://community.aseprite.org/t/20621
2024-02-26 17:36:57 -03:00
David Capello
a2b294b0fe Add final modifier to ToolLoopImpl to avoid clang-tidy warning
The warning is about using a virtual member function in the destructor
where it can be overridden by a derived class so in this case the
derived version wouldn't be called.

Just testing clang-tidy to see if we can add something in the CI.
2024-02-26 15:32:40 -03:00
David Capello
5dbaa295c5 Revert "Drop selection if we hide the layer (fix #4179)"
This reverts commit 078dac28d7.
2024-02-26 10:13:07 -03:00
Gaspar Capello
f22603caea Fix crash when trying to access a property of a Style which is nullptr (fix #4015)
Before this fix, an incomplete custom theme or an outdated official
theme could cause a crash during Aseprite startup.

This fix does not alert the artist the problem of the theme.
Simply avoid the crash.
2024-02-26 10:07:44 -03:00
Gaspar Capello
078dac28d7 Drop selection if we hide the layer (fix #4179) 2024-02-26 09:51:36 -03:00
David Capello
6ab2731fad Remove verbosity in .exe file description on Windows (fix #4333) 2024-02-23 20:00:01 -03:00
David Capello
10dda30a15 Don't write color2 chunk for files with more than 256 colors (fix #4322)
We were incorrectly saving a wrong number of entries for palettes with
more than 256 colors in color2 chunk, anyway it doesn't make sense to
use this chunks as it doesn't support more than 256 colors. So we
removed it for this case.

We've also removed the palette chunk for cases where it's not required
at all, e.g. when we have less than 256 colors and doesn't have alpha
channel, it makes sense to use the color2 chunk as it's smaller in the
output file.
2024-02-22 19:46:34 -03:00
David Capello
0d5075ff93 Add -noinapp option to disable Steam "in game" visibility (fix #4314)
Some minor changes in this commit includes the usage of
std::unique_ptr for the Pimpl-idiom in steam::SteamAPI class and
renaming the SteamAPI::initialized() to SteamAPI::isInitialized() to
avoid confusion reading the code.

Forum post:
https://steamcommunity.com/app/431730/discussions/2/7260435303111061192/
2024-02-21 12:47:27 -03:00
David Capello
5337a728be Fix platform version for Windows 10/11
Now we include the 10.0 + the build number in the version.
2024-02-20 18:08:46 -03:00
David Capello
d70801e88b Throw a bad_alloc when there is not enough memory for ImageBuffer (fix #4316)
Fix regression introduced in aeeef8e255
when we replaced the std::vector with aligned memory allocations (or
just malloc/free).
2024-02-19 11:21:53 -03:00
David Capello
0134c74926 Fix gcc error: expected primary-expression before ‘unsigned’ 2024-02-16 14:49:41 -03:00
David Capello
644b0021fb Replace ’ unicode char with ' for news description 2024-02-16 14:10:16 -03:00
David Capello
57bc038ced Add some extra chars in mini font for Spanish (ñ, Á, ó, part of #4307) 2024-02-16 12:59:36 -03:00
David Capello
5e83ceb9a7 Update checkout GitHub action to avoid warning about deprecated node.js 16
https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/
2024-02-16 12:42:53 -03:00
David Capello
9be7c66376 Add possibility to paste as new file from clipboard on Home tab
Feature request:
https://community.aseprite.org/t/pasting-on-home-screen/21476
2024-02-16 12:40:00 -03:00
David Capello
a1b52fd64b Fix enabling commands when they need to write a document in certain cases (fix #4310)
In certain situations a script creating a transaction could run
certain commands (or functions running commands) that will ask if the
command is enabled before executing it (Command::executeCommand()).

ContextFlags::update() is the function that checks if we can upgrade a
reader lock to a writer, which means that we can write the
document. The new fix in laf's RWLock::canWriteLockFromRead() makes
this condition work correctly.
2024-02-16 12:18:55 -03:00
Gaspar Capello
243982ab78 Fix identify running Aseprite processes correctly to recover crashed sessions (related to #4130)
Prior to this fix, Aseprite was hiding some sessions to recover,
resulting in additional support for users.
To display available recovery sessions, Aseprite only checked if
the session belonged to any running process on the OS via the
'pid' number.
2024-02-15 12:10:09 -03:00
David Capello
14696de980 [lua] Update API version 2024-02-12 18:53:15 -03:00
David Capello
12623176bb Fix copying our en.ini file to strings.git clone 2024-02-12 16:55:31 -03:00
David Capello
749ea49185 Add link in About dialog to show the list of translators 2024-02-12 11:59:26 -03:00
Martín Capello
a7d4c23af9 Fix exporting one tag without "play subtags/repeats" and changing its anidir (fix #4297) 2024-02-09 17:31:25 -03:00
Gaspar Capello
45e74c7338 Fix HSV/HSL values on ColorSliders
Before this fix, the HSV and HSV values displayed in the ColorSliders were truncated rather than rounded to the nearest integer.
2024-02-08 19:16:08 -03:00
David Capello
d7dfe4b7fd Update laf module 2024-02-08 18:58:39 -03:00
David Capello
916b3bf26a Fix Steam screenshots (fix #4300)
Steam API/DLL now contains a SteamAPI_InitSafe() function for backward
compatibility similar to the old SteamAPI_Init(). The official
"steam_api.h" header file contains inline-defined functions for
SteamAPI_Init() and SteamAPI_InitEx() but both use the published
SteamInternal_SteamAPI_Init() function (we don't need it, I guess, so
SteamAPI_InitSafe() is enough for us).
2024-02-08 18:43:38 -03:00
David Capello
434c262489 Merge branch 'intuitive-opacity-values' (#1544, #4262) 2024-02-08 15:22:58 -03:00
Martín Capello
f7f2c56abf [lua] Fix tabs ID handling (fix #4268) 2024-02-08 10:55:46 -03:00
Martín Capello
9ef6c4848d Avoid exposing doc::frames types to the global namespace 2024-02-07 14:04:35 -03:00
Martín Capello
fdafc585c2 Adjust alpha color slider to make it work as percentage or value as specified by the preference settings 2024-02-07 13:33:09 -03:00
Martín Capello
b10390625f Introduce AlphaEntry class and make InkOpacityField extend from it (fix #1544) 2024-02-07 13:33:09 -03:00
Martín Capello
dd0e5addc9 Replace slider by opacityslider (fix #1544) 2024-02-07 13:33:09 -03:00
Martín Capello
04cf5eaa15 Introduce "alphaslider" and "opacityslider" controls. Use "opacityslider" in cel properties (fix #1544)
They work like a regular slider but use 0%-100% or 0-255 ranges depending on configuration settings.
2024-02-07 13:33:04 -03:00
David Capello
9318ce4941 Merge branch 'export-with-play-subtags' (#4173, #4211) 2024-02-07 11:58:28 -03:00