diff options
author | sr55 <[email protected]> | 2018-11-04 17:23:24 +0000 |
---|---|---|
committer | sr55 <[email protected]> | 2018-11-04 17:23:24 +0000 |
commit | e566794de8b26fc97b1d4316eb6170a482d022c1 (patch) | |
tree | 02bd95f6db59c0bcb31653f2fade59edf649aa25 /win/CS | |
parent | f150842bcf21ad649438eb1de1f86e2ef4321615 (diff) |
WinGui: Better default directory for Import SRT. #1661
Diffstat (limited to 'win/CS')
-rw-r--r-- | win/CS/HandBrakeWPF/ViewModels/SubtitlesViewModel.cs | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/win/CS/HandBrakeWPF/ViewModels/SubtitlesViewModel.cs b/win/CS/HandBrakeWPF/ViewModels/SubtitlesViewModel.cs index 3d26296fd..fb8dc838c 100644 --- a/win/CS/HandBrakeWPF/ViewModels/SubtitlesViewModel.cs +++ b/win/CS/HandBrakeWPF/ViewModels/SubtitlesViewModel.cs @@ -244,6 +244,15 @@ namespace HandBrakeWPF.ViewModels Multiselect = true
};
+ if (this.Task != null && this.Task.Source != null)
+ {
+ string path = Path.GetDirectoryName(this.Task.Source);
+ if (Directory.Exists(path))
+ {
+ dialog.InitialDirectory = path;
+ }
+ }
+
dialog.ShowDialog();
this.AddInputSubtitles(dialog.FileNames);
|