diff --git a/aegisub/src/video_context.cpp b/aegisub/src/video_context.cpp index 60416d71b..a358c6728 100644 --- a/aegisub/src/video_context.cpp +++ b/aegisub/src/video_context.cpp @@ -248,12 +248,13 @@ void VideoContext::OnSubtitlesCommit() { } void VideoContext::OnSubtitlesSave() { + context->ass->SetScriptInfo("VFR File", MakeRelativePath(GetTimecodesName(), context->ass->filename)); + context->ass->SetScriptInfo("Keyframes File", MakeRelativePath(GetKeyFramesName(), context->ass->filename)); + if (!IsLoaded()) { context->ass->SetScriptInfo("Video File", ""); context->ass->SetScriptInfo("Video Aspect Ratio", ""); context->ass->SetScriptInfo("Video Position", ""); - context->ass->SetScriptInfo("VFR File", ""); - context->ass->SetScriptInfo("Keyframes File", ""); return; } @@ -267,8 +268,6 @@ void VideoContext::OnSubtitlesSave() { context->ass->SetScriptInfo("YCbCr Matrix", videoProvider->GetColorSpace()); context->ass->SetScriptInfo("Video Aspect Ratio", ar); context->ass->SetScriptInfo("Video Position", wxString::Format("%d", frame_n)); - context->ass->SetScriptInfo("VFR File", MakeRelativePath(GetTimecodesName(), context->ass->filename)); - context->ass->SetScriptInfo("Keyframes File", MakeRelativePath(GetKeyFramesName(), context->ass->filename)); } void VideoContext::JumpToFrame(int n) {