summaryrefslogtreecommitdiffstats
path: root/win/CS/HandBrakeWPF/Utilities
diff options
context:
space:
mode:
Diffstat (limited to 'win/CS/HandBrakeWPF/Utilities')
-rw-r--r--win/CS/HandBrakeWPF/Utilities/DirectoryUtilities.cs2
-rw-r--r--win/CS/HandBrakeWPF/Utilities/ExtensionMethods.cs2
-rw-r--r--win/CS/HandBrakeWPF/Utilities/GeneralUtilities.cs18
-rw-r--r--win/CS/HandBrakeWPF/Utilities/Input/ChapterImporterTxt.cs3
-rw-r--r--win/CS/HandBrakeWPF/Utilities/Portable.cs2
-rw-r--r--win/CS/HandBrakeWPF/Utilities/SystemInfo.cs8
6 files changed, 18 insertions, 17 deletions
diff --git a/win/CS/HandBrakeWPF/Utilities/DirectoryUtilities.cs b/win/CS/HandBrakeWPF/Utilities/DirectoryUtilities.cs
index df7f2a1a3..7a58721b3 100644
--- a/win/CS/HandBrakeWPF/Utilities/DirectoryUtilities.cs
+++ b/win/CS/HandBrakeWPF/Utilities/DirectoryUtilities.cs
@@ -71,7 +71,7 @@ namespace HandBrakeWPF.Utilities
if (!Directory.Exists(dirPath))
{
MessageBoxResult result = errorService.ShowMessageBox(string.Format(Resources.DirectoryUtils_CreateFolderMsg, dirPath), Resources.DirectoryUtils_CreateFolder, MessageBoxButton.YesNo, MessageBoxImage.Question);
- if (MessageBoxResult.Yes == result)
+ if (result == MessageBoxResult.Yes)
{
Directory.CreateDirectory(dirPath);
}
diff --git a/win/CS/HandBrakeWPF/Utilities/ExtensionMethods.cs b/win/CS/HandBrakeWPF/Utilities/ExtensionMethods.cs
index f25b8be8e..1379f432a 100644
--- a/win/CS/HandBrakeWPF/Utilities/ExtensionMethods.cs
+++ b/win/CS/HandBrakeWPF/Utilities/ExtensionMethods.cs
@@ -37,7 +37,9 @@ namespace HandBrakeWPF.Utilities
memberExpression = (MemberExpression)unaryExpression.Operand;
}
else
+ {
memberExpression = (MemberExpression)lambda.Body;
+ }
return memberExpression.Member;
}
diff --git a/win/CS/HandBrakeWPF/Utilities/GeneralUtilities.cs b/win/CS/HandBrakeWPF/Utilities/GeneralUtilities.cs
index 18583acd8..2492de888 100644
--- a/win/CS/HandBrakeWPF/Utilities/GeneralUtilities.cs
+++ b/win/CS/HandBrakeWPF/Utilities/GeneralUtilities.cs
@@ -107,15 +107,15 @@ namespace HandBrakeWPF.Utilities
gpuBuilder.Append("GPU Information is unavailable");
}
- logHeader.AppendLine(String.Format("HandBrake {0} - {1}", VersionHelper.GetVersion(), VersionHelper.GetPlatformBitnessVersion()));
- logHeader.AppendLine(String.Format("OS: {0} - {1}", Environment.OSVersion, Environment.Is64BitOperatingSystem ? "64bit" : "32bit"));
- logHeader.AppendLine(String.Format("CPU: {0}", SystemInfo.GetCpuCount));
- logHeader.AppendLine(String.Format("Ram: {0} MB, ", SystemInfo.TotalPhysicalMemory));
- logHeader.AppendLine(String.Format("GPU Information:{0}{1}", Environment.NewLine, gpuBuilder.ToString().TrimEnd()));
- logHeader.AppendLine(String.Format("Screen: {0}x{1}", SystemInfo.ScreenBounds.Bounds.Width, SystemInfo.ScreenBounds.Bounds.Height));
- logHeader.AppendLine(String.Format("Temp Dir: {0}", Path.GetTempPath()));
- logHeader.AppendLine(String.Format("Install Dir: {0}", Application.StartupPath));
- logHeader.AppendLine(String.Format("Data Dir: {0}\n", Application.UserAppDataPath));
+ logHeader.AppendLine(string.Format("HandBrake {0} - {1}", VersionHelper.GetVersion(), VersionHelper.GetPlatformBitnessVersion()));
+ logHeader.AppendLine(string.Format("OS: {0} - {1}", Environment.OSVersion, Environment.Is64BitOperatingSystem ? "64bit" : "32bit"));
+ logHeader.AppendLine(string.Format("CPU: {0}", SystemInfo.GetCpuCount));
+ logHeader.AppendLine(string.Format("Ram: {0} MB, ", SystemInfo.TotalPhysicalMemory));
+ logHeader.AppendLine(string.Format("GPU Information:{0}{1}", Environment.NewLine, gpuBuilder.ToString().TrimEnd()));
+ logHeader.AppendLine(string.Format("Screen: {0}x{1}", SystemInfo.ScreenBounds.Bounds.Width, SystemInfo.ScreenBounds.Bounds.Height));
+ logHeader.AppendLine(string.Format("Temp Dir: {0}", Path.GetTempPath()));
+ logHeader.AppendLine(string.Format("Install Dir: {0}", Application.StartupPath));
+ logHeader.AppendLine(string.Format("Data Dir: {0}\n", Application.UserAppDataPath));
logHeader.AppendLine("-------------------------------------------");
diff --git a/win/CS/HandBrakeWPF/Utilities/Input/ChapterImporterTxt.cs b/win/CS/HandBrakeWPF/Utilities/Input/ChapterImporterTxt.cs
index f9e2acee9..13a88ed44 100644
--- a/win/CS/HandBrakeWPF/Utilities/Input/ChapterImporterTxt.cs
+++ b/win/CS/HandBrakeWPF/Utilities/Input/ChapterImporterTxt.cs
@@ -12,9 +12,8 @@ namespace HandBrakeWPF.Utilities.Input
{
using System;
using System.Collections.Generic;
- using System.Linq;
using System.IO;
-
+ using System.Linq;
using HandBrakeWPF.Helpers;
/// <summary>
diff --git a/win/CS/HandBrakeWPF/Utilities/Portable.cs b/win/CS/HandBrakeWPF/Utilities/Portable.cs
index 9b5981675..68eac79e2 100644
--- a/win/CS/HandBrakeWPF/Utilities/Portable.cs
+++ b/win/CS/HandBrakeWPF/Utilities/Portable.cs
@@ -9,8 +9,8 @@
namespace HandBrakeWPF.Utilities
{
- using System.Collections.Generic;
using System;
+ using System.Collections.Generic;
using System.IO;
/// <summary>
diff --git a/win/CS/HandBrakeWPF/Utilities/SystemInfo.cs b/win/CS/HandBrakeWPF/Utilities/SystemInfo.cs
index 9ed362e32..f344cf3d6 100644
--- a/win/CS/HandBrakeWPF/Utilities/SystemInfo.cs
+++ b/win/CS/HandBrakeWPF/Utilities/SystemInfo.cs
@@ -80,12 +80,12 @@ namespace HandBrakeWPF.Utilities
{
string gpu = string.Empty, version = string.Empty;
- foreach (PropertyData PC in share.Properties)
+ foreach (PropertyData pc in share.Properties)
{
- if (!string.IsNullOrEmpty(PC.Name) && PC.Value != null)
+ if (!string.IsNullOrEmpty(pc.Name) && pc.Value != null)
{
- if (PC.Name.Equals("DriverVersion")) version = PC.Value.ToString();
- if (PC.Name.Equals("Name")) gpu = PC.Value.ToString();
+ if (pc.Name.Equals("DriverVersion")) version = pc.Value.ToString();
+ if (pc.Name.Equals("Name")) gpu = pc.Value.ToString();
}
}