I've just been using the recently added Replace Audio button on Audio Tracks and am finding that if I replace the tracks with files of shorter duration, the Song Duration is not being recalculated. It does seem to re-calc if audio track with longer duration is the replacement.
As a result, aside from Song Duration being incorrect, this causes some other downstream issues: Trim End value is incorrect, Region Waveform is incorrect (even if I clear waveform cache and it redraws it), and possibly other things.
Obviously, if I do it the "older" way (add the new tracks, delete the old tracks, etc.) then everything is OK. So I suspect it is just that the Replace Audio
function to fire off a trigger to recalculate in the same way as Adding Tracks
does isn't triggering when a shorter duration file is used as the replacement.
ST4 Build: 1876
Device & iOS Version: iPad 9th Gen, iOS 26.0.1
Issue Description:
When I use Replace Audio
to replace an audio file, and the new audio file is of shorter Duration, ST is not re-calculating the Song Duration based on the new audio track.
Steps to Reproduce:
- Open a Song with an audio track
- Go to Audio tab
- In Audio Tracks, Left-swipe (or long-press) on a file and select Replace Audio
- Select a file that is shorter duration
- When you return to the Audio tab you'll notice that Trim End value is the same as before
- If you go to the Details tab, you'll notice Duration is the same as before
Expected Behavior:
Song duration should recalculate when any audio track is replaced.
Actual Behavior:
Song duration is not being recalculated if an audio track is replaced with a audio file of shorter duration.