Skip to content

Commit

Permalink
Fix for nested events in CPP
Browse files Browse the repository at this point in the history
Fixes nested events not propagating up to the parent artboard due to a recent naming change from `artboard()` to `artboardInstance()`.

Diffs=
657f65e1c Fix for nested events in CPP (#7708)

Co-authored-by: Philip Chung <[email protected]>
  • Loading branch information
philter and philter committed Jul 26, 2024
1 parent adb2822 commit 9915759
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .rive_head
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0a11e599f81bdff08afe8365b0e25115431eba8c
657f65e1c0b0c63524c65e2b5e1fbe6459e1ae69
3 changes: 2 additions & 1 deletion src/animation/state_machine_instance.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1089,7 +1089,8 @@ void StateMachineInstance::notifyEventListeners(const std::vector<EventReport>&
{
for (const auto event : events)
{
auto sourceArtboard = source == nullptr ? artboard() : source->artboard();
auto sourceArtboard =
source == nullptr ? artboard() : source->artboardInstance();

// listener->eventId() can point to an id from an event in the context of this
// artboard or the context of a nested artboard. Because those ids belong to
Expand Down

0 comments on commit 9915759

Please sign in to comment.