Build cleanly under clang, and name the remaining booleans with is

Exported XML templates lose the static clang rejects. Unused this captures,
a dead null check, an undefined declaration, an unused constant and stray
semicolons go, and single statements lose their braces.
This commit is contained in:
shweet committed 2026-11-22 19:35:33 -05:00
1 parent c5a2bddfa1
commit f35f9cb4b8
21 files changed
+59 -72

No files matched your search

+4 -4
View File
@@ -143,7 +143,7 @@ void AnimationPreview::tick(Manager& manager, Settings& settings, float deltaSec
recording_stop(manager, document);
}
stop_all_sounds();
wasPlaybackPlaying = false;
isPlaybackPlayingBefore = false;
return;
}
@@ -161,7 +161,7 @@ void AnimationPreview::tick(Manager& manager, Settings& settings, float deltaSec
{
auto fps = std::max(model.info.fps, 1);
auto range = animation_play_range_get(*animation);
if (!wasPlaybackPlaying)
if (!isPlaybackPlayingBefore)
soundFrame = (int)std::floor(playback.time) - 1;
auto isLoop = (animation->isLoop || settings.playbackIsLoop) && !manager.isRecording;
playback.tick(fps, range.x, range.y, isLoop ? PLAYBACK_LOOP : PLAYBACK_ONCE, deltaSeconds);
@@ -181,9 +181,9 @@ void AnimationPreview::tick(Manager& manager, Settings& settings, float deltaSec
}
}
if (wasPlaybackPlaying && !playback.isPlaying)
if (isPlaybackPlayingBefore && !playback.isPlaying)
stop_all_sounds();
wasPlaybackPlaying = playback.isPlaying;
isPlaybackPlayingBefore = playback.isPlaying;
}
void AnimationPreview::recording_stop(Manager& manager, Document& document)