forked from mia/Aegisub
Store the loaded audio file as a path relative to the subtitles, as is done with video
Originally committed to SVN as r6710.
This commit is contained in:
parent
15eb4dc29d
commit
3c31c1a17a
2 changed files with 3 additions and 2 deletions
|
@ -56,6 +56,7 @@
|
|||
#include "main.h"
|
||||
#include "selection_controller.h"
|
||||
#include "standard_paths.h"
|
||||
#include "utils.h"
|
||||
#include "video_context.h"
|
||||
|
||||
AudioController::AudioController(agi::Context *context)
|
||||
|
@ -311,7 +312,7 @@ void AudioController::OnSubtitlesSave()
|
|||
{
|
||||
if (IsAudioOpen())
|
||||
{
|
||||
context->ass->SetScriptInfo("Audio URI", audio_url);
|
||||
context->ass->SetScriptInfo("Audio URI", MakeRelativePath(audio_url, context->ass->filename));
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
@ -645,7 +645,7 @@ void FrameMain::OnSubtitlesOpen() {
|
|||
wxString curSubsVideo = DecodeRelativePath(context->ass->GetScriptInfo("Video File"), context->ass->filename);
|
||||
wxString curSubsVFR = DecodeRelativePath(context->ass->GetScriptInfo("VFR File"), context->ass->filename);
|
||||
wxString curSubsKeyframes = DecodeRelativePath(context->ass->GetScriptInfo("Keyframes File"), context->ass->filename);
|
||||
wxString curSubsAudio = context->ass->GetScriptInfo("Audio URI");
|
||||
wxString curSubsAudio = DecodeRelativePath(context->ass->GetScriptInfo("Audio URI"), context->ass->filename);
|
||||
|
||||
bool videoChanged = !blockVideoLoad && curSubsVideo != context->videoController->GetVideoName();
|
||||
bool timecodesChanged = curSubsVFR != context->videoController->GetTimecodesName();
|
||||
|
|
Loading…
Reference in a new issue