{\r
class Main\r
{\r
- /// <summary>\r
- /// Take in a File destination and change it's file extension to a new Extension\r
- /// </summary>\r
- /// <param name="destination"></param>\r
- /// <param name="newExtension"></param>\r
- /// <returns>String of the new file path and extension</returns>\r
- public string setExtension(string destination, string newExtension)\r
- {\r
- destination.Replace(".mp4", newExtension);\r
- destination.Replace(".m4v", newExtension);\r
- destination.Replace(".mkv", newExtension);\r
- destination.Replace(".avi", newExtension);\r
- destination.Replace(".ogm", newExtension);\r
-\r
- return destination;\r
- }\r
-\r
/// <summary>\r
/// Calculate the duration of the selected title and chapters\r
/// </summary>\r
private void drop_format_SelectedIndexChanged(object sender, EventArgs e)\r
{\r
if (drop_format.SelectedIndex == 0)\r
- text_destination.Text = hb_common_func.setExtension(text_destination.Text, ".mp4");\r
+ setExtension(".mp4");\r
else if (drop_format.SelectedIndex == 1)\r
- text_destination.Text = hb_common_func.setExtension(text_destination.Text, ".m4v");\r
+ setExtension(".m4v");\r
else if (drop_format.SelectedIndex == 2)\r
- text_destination.Text = hb_common_func.setExtension(text_destination.Text, ".mkv");\r
+ setExtension(".mkv");\r
else if (drop_format.SelectedIndex == 3)\r
- text_destination.Text = hb_common_func.setExtension(text_destination.Text, ".avi");\r
+ setExtension(".avi");\r
else if (drop_format.SelectedIndex == 4)\r
- text_destination.Text = hb_common_func.setExtension(text_destination.Text, ".ogm");\r
+ setExtension(".ogm");\r
+\r
}\r
\r
//Video Tab\r
}\r
}\r
}\r
+ /// <summary>\r
+ /// Take in a File destination and change it's file extension to a new Extension\r
+ /// </summary>\r
+ /// <param name="destination"></param>\r
+ /// <param name="newExtension"></param>\r
+ /// <returns>String of the new file path and extension</returns>\r
+ public void setExtension(string newExtension)\r
+ {\r
+ text_destination.Text = text_destination.Text.Replace(".mp4", newExtension);\r
+ text_destination.Text = text_destination.Text.Replace(".m4v", newExtension);\r
+ text_destination.Text = text_destination.Text.Replace(".mkv", newExtension);\r
+ text_destination.Text = text_destination.Text.Replace(".avi", newExtension);\r
+ text_destination.Text = text_destination.Text.Replace(".ogm", newExtension);\r
+ }\r
#endregion\r
\r
#region Drive Detection\r