Item Properties shares Layer Properties' source fields
New layers added from the timeline can play an animation too: both popups draw the source with layer_source_draw and build the item from the same ItemEdit, and edit::item_add takes the new layer or null whole. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
af60cdc11c
commit
6b6cd671f7
7 files changed
+91
-94
No files matched your search
@@ -58,8 +58,9 @@ TEST_CASE("file_merge presets")
|
||||
TEST_CASE("item_add")
|
||||
{
|
||||
auto model = fixture_load("02_items.anm2");
|
||||
CHECK(edit::item_add(model, ItemType::LAYER, 0, -1, "added", 1, false, 1, types::destination::ALL) == 2);
|
||||
CHECK(edit::item_add(model, ItemType::NULL_, 1, -1, "thisOnly", 0, false, -1, types::destination::THIS) == 2);
|
||||
CHECK(edit::item_add(model, ItemType::LAYER, 0, -1, {.name = "added", .spritesheetId = 1}, {}, 1,
|
||||
types::destination::ALL) == 2);
|
||||
CHECK(edit::item_add(model, ItemType::NULL_, 1, -1, {}, {.name = "thisOnly"}, -1, types::destination::THIS) == 2);
|
||||
operation_check("item_add", model);
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user