diff options
author | sr55 <[email protected]> | 2013-05-26 16:28:07 +0000 |
---|---|---|
committer | sr55 <[email protected]> | 2013-05-26 16:28:07 +0000 |
commit | 7569b18d51170f3b421b5b77df02b5b0a0e2dda0 (patch) | |
tree | ee98ffb4cbfdbb0715744e2bec6934f34d78bc6b /win/CS/HandBrakeWPF/Helpers | |
parent | 32266ab3a804f29a3979b2c1880969d2b4d24e4a (diff) |
Merging Trunk to OpenCL
git-svn-id: svn://svn.handbrake.fr/HandBrake/branches/opencl@5518 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'win/CS/HandBrakeWPF/Helpers')
-rw-r--r-- | win/CS/HandBrakeWPF/Helpers/AutoNameHelper.cs | 4 | ||||
-rw-r--r-- | win/CS/HandBrakeWPF/Helpers/CliCheckHelper.cs | 5 |
2 files changed, 5 insertions, 4 deletions
diff --git a/win/CS/HandBrakeWPF/Helpers/AutoNameHelper.cs b/win/CS/HandBrakeWPF/Helpers/AutoNameHelper.cs index 5c4e83cb1..2298eb4ab 100644 --- a/win/CS/HandBrakeWPF/Helpers/AutoNameHelper.cs +++ b/win/CS/HandBrakeWPF/Helpers/AutoNameHelper.cs @@ -79,8 +79,8 @@ namespace HandBrakeWPF.Helpers {
destinationFilename = userSettingService.GetUserSetting<string>(UserSettingConstants.AutoNameFormat);
destinationFilename = destinationFilename.Replace("{source}", sourceName)
- .Replace("{title}", dvdTitle)
- .Replace("{chapters}", combinedChapterTag)
+ .Replace(Constants.Title, dvdTitle)
+ .Replace(Constants.Chapters, combinedChapterTag)
.Replace("{date}", DateTime.Now.Date.ToShortDateString().Replace('/', '-'));
}
else
diff --git a/win/CS/HandBrakeWPF/Helpers/CliCheckHelper.cs b/win/CS/HandBrakeWPF/Helpers/CliCheckHelper.cs index 2e69eacec..0060b1d15 100644 --- a/win/CS/HandBrakeWPF/Helpers/CliCheckHelper.cs +++ b/win/CS/HandBrakeWPF/Helpers/CliCheckHelper.cs @@ -14,6 +14,7 @@ namespace HandBrakeWPF.Helpers using System.IO;
using System.Security.Cryptography;
using System.Text.RegularExpressions;
+ using System.Windows.Forms;
using Caliburn.Micro;
@@ -43,7 +44,7 @@ namespace HandBrakeWPF.Helpers // Get the SHA1 Hash of HandBrakeCLI
byte[] hash;
- using (Stream stream = File.OpenRead("HandBrakeCLI.exe"))
+ using (Stream stream = File.OpenRead(Path.Combine(Application.StartupPath, "HandBrakeCLI.exe")))
{
hash = SHA1.Create().ComputeHash(stream);
}
@@ -58,7 +59,7 @@ namespace HandBrakeWPF.Helpers // It's not the same, so start the CLI to get it's version data.
Process cliProcess = new Process();
- ProcessStartInfo handBrakeCli = new ProcessStartInfo("HandBrakeCLI.exe", " -u -v0")
+ ProcessStartInfo handBrakeCli = new ProcessStartInfo(Path.Combine(Application.StartupPath, "HandBrakeCLI.exe"), " -u -v0")
{
UseShellExecute = false,
RedirectStandardError = true,
|