summaryrefslogtreecommitdiffstats
path: root/win/C#/Functions
diff options
context:
space:
mode:
authorsr55 <[email protected]>2008-09-19 16:50:52 +0000
committersr55 <[email protected]>2008-09-19 16:50:52 +0000
commitffb762dd2e74f1c4f0dd573ff054205bc4bc2655 (patch)
treeba95ac24356c1c6800cd27f95c2978152556574e /win/C#/Functions
parent587179e9ef92374b640db3fde41427557972c026 (diff)
WinGui:
- Just allow ISO_Open to open all files. Will save adding all the ffmpeg options available. - Re-factored the chapter marker creation/query generation code. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1731 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'win/C#/Functions')
-rw-r--r--win/C#/Functions/Common.cs35
1 files changed, 10 insertions, 25 deletions
diff --git a/win/C#/Functions/Common.cs b/win/C#/Functions/Common.cs
index 41f6e71f6..b55c8e566 100644
--- a/win/C#/Functions/Common.cs
+++ b/win/C#/Functions/Common.cs
@@ -860,7 +860,7 @@ namespace Handbrake.Functions
// This is for the queue. It allows different chapter name files for each title.
string source_name = mainWindow.text_source.Text;
string[] sourceName = source.Split('\\');
- source_name = sourceName[sourceName.Length - 1].Replace(".iso", "").Replace(".mpg", "").Replace(".ts", "").Replace(".ps", "");
+ source_name = sourceName[sourceName.Length - 1];
source_name = source_name.Replace("\"", "");
string source_title = mainWindow.drp_dvdtitle.Text;
@@ -869,36 +869,21 @@ namespace Handbrake.Functions
if (mainWindow.Check_ChapterMarkers.Checked)
{
- if ((source_name.Trim().Replace("-i ", "") != "Click 'Browse' to continue") && (source_name.Trim().Replace("-i ", "") != ""))
+ if ((source_name.Trim() != "Click 'Source' to continue") && (source_name.Trim() != ""))
{
+ string path = "";
if (source_title != "Automatic")
- {
- string filename = source_name + "-" + source_title + "-chapters.csv";
- string path = Path.Combine(Path.GetTempPath(), filename);
-
- Boolean saveCSV = chapterCSVSave(mainWindow, path);
- if (saveCSV == false)
- query += " -m ";
- else
- query += " --markers=" + "\"" + path + "\"";
- }
+ path = Path.Combine(Path.GetTempPath(), source_name + "-" + source_title + "-chapters.csv");
else
- {
- string filename = source_name + "-chapters.csv";
- string path = Path.Combine(Path.GetTempPath(), filename);
+ path = Path.Combine(Path.GetTempPath(), source_name + "-chapters.csv");
- Boolean saveCSV = chapterCSVSave(mainWindow, path);
- if (saveCSV == false)
- query += " -m ";
- else
- query += " --markers=" + "\"" + path + "\"";
- }
+ if (chapterCSVSave(mainWindow, path) == false)
+ query += " -m ";
+ else
+ query += " --markers=" + "\"" + path + "\"";
}
else
- {
- string path = Path.Combine(Path.GetTempPath(), "chapters.csv");
- query += " --markers=" + "\"" + path + "\"";
- }
+ query += " -m";
}
#endregion