small improvements

-added sub file format selection
-added error resolution saving
-improvements for cancelling downloads in hybrid mode
-added episode naming options
This commit is contained in:
hama3254 2020-11-21 14:56:27 +01:00
parent 754f38daef
commit 09e39fef4d
13 changed files with 372 additions and 53 deletions

Binary file not shown.

View File

@ -71,7 +71,9 @@ Public Class CRD_List_Item
Return StatusRunning
End Function
Public Function GetIsStatusFinished() As Boolean
If HybridRunning = True Then
If Canceld = True Then
Return True
ElseIf HybridRunning = True Then
Return False
Else
If proc.HasExited = True Then
@ -169,7 +171,27 @@ Public Class CRD_List_Item
End Sub
Private Sub bt_pause_Click(sender As Object, e As EventArgs) Handles bt_pause.Click
If HybridRunning = True Then
If Canceld = True And HybridRunning = True Then
If Main.RunningDownloads < Main.MaxDL Then
Else
If MessageBox.Show("You have currtenly on your set Download limit." + vbNewLine + " You can Press OK to ignore it.", "Download maximum reached", MessageBoxButtons.OKCancel) = DialogResult.Cancel Then
Exit Sub
End If
End If
Canceld = False
'If My.Computer.FileSystem.FileExists(HistoryDL_Pfad.Replace(Chr(34), "")) Then 'Pfad = Kompeltter Pfad mit Dateinamen + ENdung
' Try
' My.Computer.FileSystem.DeleteFile(HistoryDL_Pfad.Replace(Chr(34), ""))
' Catch ex As Exception
' End Try
'End If
StartDownload(HistoryDL_URL, HistoryDL_Pfad, HistoryFilename, HybridMode)
StatusRunning = True
Label_website.Text = Label_website_Text
Exit Sub
ElseIf HybridRunning = True Then
If StatusRunning = True Then
StatusRunning = False
bt_pause.BackgroundImage = My.Resources.main_pause_play
@ -178,6 +200,7 @@ Public Class CRD_List_Item
StatusRunning = True
bt_pause.BackgroundImage = My.Resources.main_pause
End If
Else
If proc.HasExited = True Then
If ProgressBar1.Value < 100 Then
@ -505,6 +528,12 @@ Public Class CRD_List_Item
System.IO.Directory.Delete(HybridModePath, True)
Catch ex As Exception
End Try
Me.Invoke(New Action(Function()
ProgressBar1.Value = 0
Label_percent.Text = "canceled -%"
bt_pause.BackgroundImage = My.Resources.main_pause_play
Return Nothing
End Function))
Exit For
End If
Next
@ -947,12 +976,18 @@ Public Class CRD_List_Item
#End Region
Private Sub bt_del_Click(sender As Object, e As EventArgs) Handles bt_del.Click
If HybridRunning = True Then
If Canceld = True Then
If MessageBox.Show("The Download is not running anymore, press ok to remove it from the list.", "Remove from list!", MessageBoxButtons.OKCancel) = DialogResult.Cancel Then
Exit Sub
End If
ToDispose = True
ElseIf HybridRunning = True Then
If MessageBox.Show("Are you sure you want to cancel the Download?", "Cancel Download!", MessageBoxButtons.YesNo) = DialogResult.No Then
Exit Sub
End If
Canceld = True
'KillRunningTask()
Else
If proc.HasExited Then
If MessageBox.Show("The Download is not running anymore, press ok to remove it from the list.", "Remove from list!", MessageBoxButtons.OKCancel) = DialogResult.Cancel Then

View File

@ -55,6 +55,7 @@ Public Class Main
Dim Reso2 As String
Public ResoSave As String = "6666x6666"
Public ResoFunBackup As String = "6666x6666"
Public SubSprache As String
Public SubFolder As Integer
Public SoftSubs As New List(Of String)
@ -71,6 +72,7 @@ Public Class Main
Public Funimation_Grapp_RDY As Boolean = True
Public Grapp_non_cr_RDY As Boolean = True
Public Grapp_Abord As Boolean = False
Public CR_NameMethode As Integer = 0
Public MaxDL As Integer
Public ResoNotFoundString As String
Public ResoBackString As String
@ -84,6 +86,9 @@ Public Class Main
Public HybridMode As Boolean = False
Public HardSubFunimation As String = "Disabled"
Public DubFunimation As String = "Disabled"
Public Funimation_srt As Boolean = False
Public Funimation_vtt As Boolean = False
Public Funimation_dfxp As Boolean = False
Public SubFunimationString As String = "en"
Public SubFunimation As New List(Of String)
#Region "Sprachen Vairablen"
@ -396,6 +401,13 @@ Public Class Main
MaxDL = 1
End Try
Try
Dim rkg As RegistryKey = Registry.CurrentUser.OpenSubKey("Software\CRDownloader")
CR_NameMethode = Integer.Parse(rkg.GetValue("CR_NameMethode").ToString)
Catch ex As Exception
CR_NameMethode = 0
End Try
Try
Dim rkg As RegistryKey = Registry.CurrentUser.OpenSubKey("Software\CRDownloader")
ErrorTolerance = Integer.Parse(rkg.GetValue("ErrorTolerance").ToString)
@ -413,6 +425,24 @@ Public Class Main
HybridMode = CBool(Integer.Parse(rkg.GetValue("HybridMode").ToString))
Catch ex As Exception
End Try
Try
Dim rkg As RegistryKey = Registry.CurrentUser.OpenSubKey("Software\CRDownloader")
Funimation_srt = CBool(Integer.Parse(rkg.GetValue("Funimation_srt").ToString))
Catch ex As Exception
End Try
Try
Dim rkg As RegistryKey = Registry.CurrentUser.OpenSubKey("Software\CRDownloader")
Funimation_vtt = CBool(Integer.Parse(rkg.GetValue("Funimation_vtt").ToString))
Catch ex As Exception
End Try
Try
Dim rkg As RegistryKey = Registry.CurrentUser.OpenSubKey("Software\CRDownloader")
Funimation_dfxp = CBool(Integer.Parse(rkg.GetValue("Funimation_dfxp").ToString))
Catch ex As Exception
End Try
Try
Dim rkg As RegistryKey = Registry.CurrentUser.OpenSubKey("Software\CRDownloader")
@ -1290,6 +1320,7 @@ Public Class Main
Dim CR_Anime_Dub As String = Nothing
Dim CR_Anime_Staffel As String = Nothing
Dim CR_Anime_Folge As String = Nothing
Dim CR_Anime_Name As String = Nothing
#Region "Name + Pfad"
Dim Pfad2 As String
Dim TextBox2_Text As String = Nothing
@ -1345,16 +1376,43 @@ Public Class Main
Dim CR_Name_Anime0 As String() = CR_Name_4(CR_Name_4.Length - 1).Split(New String() {"</a>"}, System.StringSplitOptions.RemoveEmptyEntries)
CR_Name_Anime0(0) = System.Text.RegularExpressions.Regex.Replace(CR_Name_Anime0(0), "[^\w\\-]", " ")
CR_Anime_Titel = CR_Name_Anime0(0).Trim
If CR_Anime_Staffel = Nothing Then
CR_FilenName = CR_Anime_Titel + " " + CR_Anime_Folge
Else
CR_FilenName = CR_Anime_Titel + " " + CR_Anime_Staffel + " " + CR_Anime_Folge
End If
CR_FilenName_Backup = RemoveExtraSpaces(CR_FilenName)
End If
If CBool(InStr(WebbrowserText, "vilos.config.player.pause_screen.text = " + Chr(34))) Then
Dim CR_Name_1 As String() = WebbrowserText.Split(New String() {"vilos.config.player.pause_screen.text = " + Chr(34)}, System.StringSplitOptions.RemoveEmptyEntries)
Dim CR_Name_2 As String() = CR_Name_1(1).Split(New String() {Chr(34) + ";"}, System.StringSplitOptions.RemoveEmptyEntries) '(New [Char]() {"-"})
CR_Anime_Name = System.Text.RegularExpressions.Regex.Replace(CR_Name_2(0), "[^\w\\-]", " ")
CR_Anime_Name = RemoveExtraSpaces(CR_Anime_Name)
End If
If CR_NameMethode = 0 Then
If CR_Anime_Staffel = Nothing Then
CR_FilenName = CR_Anime_Titel + " " + CR_Anime_Folge
Else
CR_FilenName = CR_Anime_Titel + " " + CR_Anime_Staffel + " " + CR_Anime_Folge
End If
ElseIf CR_NameMethode = 1 Then
If CR_Anime_Staffel = Nothing Then
CR_FilenName = CR_Anime_Titel + " " + CR_Anime_Name
Else
CR_FilenName = CR_Anime_Titel + " " + CR_Anime_Staffel + " " + CR_Anime_Name
End If
ElseIf CR_NameMethode = 2 Then
If CR_Anime_Staffel = Nothing Then
CR_FilenName = CR_Anime_Titel + " " + CR_Anime_Folge + " " + CR_Anime_Name
Else
CR_FilenName = CR_Anime_Titel + " " + CR_Anime_Staffel + " " + CR_Anime_Folge + " " + CR_Anime_Name
End If
End If
#End Region
Else
@ -2112,6 +2170,7 @@ Public Class Main
Dim FunimationSeason As String = Nothing
Dim FunimationEpisode As String = Nothing
Dim FunimationTitle As String = Nothing
Dim FunimationEpisodeTitle As String = Nothing
Dim FunimationDub As String = Nothing
Dim FunimationSeason1() As String = WebbrowserText.Split(New String() {"seasonNum: "}, System.StringSplitOptions.RemoveEmptyEntries)
@ -2126,13 +2185,25 @@ Public Class Main
Dim FunimationTitle2() As String = FunimationTitle1(1).Split(New String() {"';"}, System.StringSplitOptions.RemoveEmptyEntries)
FunimationTitle = System.Text.RegularExpressions.Regex.Replace(FunimationTitle2(0), "[^\w\\-]", " ").Trim(" ")
FunimationTitle = RemoveExtraSpaces(FunimationTitle)
Dim FunimationDub1() As String = WebbrowserText.Split(New String() {".showLanguage = '"}, System.StringSplitOptions.RemoveEmptyEntries)
Dim FunimationDub2() As String = FunimationDub1(1).Split(New String() {"';"}, System.StringSplitOptions.RemoveEmptyEntries)
FunimationDub = FunimationDub2(0)
Dim FunimationEpisodeTitle1() As String = WebbrowserText.Split(New String() {".videoTitle = '"}, System.StringSplitOptions.RemoveEmptyEntries)
Dim FunimationEpisodeTitle2() As String = FunimationEpisodeTitle1(1).Split(New String() {"';"}, System.StringSplitOptions.RemoveEmptyEntries)
FunimationEpisodeTitle = System.Text.RegularExpressions.Regex.Replace(FunimationEpisodeTitle2(0), "[^\w\\-]", " ").Trim(" ")
FunimationEpisodeTitle = RemoveExtraSpaces(FunimationEpisodeTitle)
Dim DefaultName As String = RemoveExtraSpaces(FunimationTitle + " " + FunimationSeason + " " + FunimationEpisode)
If CR_NameMethode = 1 Then
DefaultName = RemoveExtraSpaces(FunimationTitle + " " + FunimationSeason + " " + FunimationEpisodeTitle)
ElseIf CR_NameMethode = 2 Then
DefaultName = RemoveExtraSpaces(FunimationTitle + " " + FunimationSeason + " " + FunimationEpisode + " " + FunimationEpisodeTitle)
End If
Dim DefaultPath As String = Pfad + "\" + DefaultName + ".mp4"
#End Region
@ -2280,7 +2351,7 @@ Public Class Main
'MsgBox(Funimation_m3u8_Main)
Dim FunimationBackupm3u8 As String = Nothing
For i As Integer = 0 To textLenght.Length - 1
Try
If InStr(textLenght(i), "https") Then
@ -2315,6 +2386,42 @@ Public Class Main
CheckClient2.Encoding = System.Text.Encoding.UTF8
Dim testdl As String = CheckClient2.DownloadString(keyfileurl3)
Funimation_m3u8_final = textLenght(i)
FunimationBackupm3u8 = textLenght(i)
Exit For
Catch ex As Exception
Debug.WriteLine(keyfileurl3 + vbNewLine + vbNewLine + ex.ToString)
End Try
ElseIf InStr(textLenght(i - 1), ResoFunBackup) Then
Dim CheckClient As New WebClient
CheckClient.Encoding = Encoding.UTF8
If WebbrowserCookie = Nothing Then
Else
CheckClient.Headers.Add(HttpRequestHeader.Cookie, WebbrowserCookie)
End If
Dim m3u8String As String = CheckClient.DownloadString(textLenght(i))
Dim keyfileurl() As String = m3u8String.Split(New String() {"URI=" + Chr(34)}, System.StringSplitOptions.RemoveEmptyEntries)
Dim keyfileurl2() As String = keyfileurl(1).Split(New String() {Chr(34) + ","}, System.StringSplitOptions.RemoveEmptyEntries)
Dim keyfileurl3 As String = keyfileurl2(0)
If InStr(keyfileurl2(0), "https://") Then
Else
Dim c() As String = New Uri(textLenght(i)).Segments
Dim path As String = "https://" + New Uri(textLenght(i)).Host
For i3 As Integer = 0 To c.Count - 2
path = path + c(i3)
Next
keyfileurl3 = path + keyfileurl2(0) 'New Uri(textLenght(i)).LocalPath + keyfileurl2(0)
End If
'MsgBox(keyfileurl3)
Try
Dim CheckClient2 As New WebClient
CheckClient2.Encoding = System.Text.Encoding.UTF8
Dim testdl As String = CheckClient2.DownloadString(keyfileurl3)
FunimationBackupm3u8 = textLenght(i)
Exit For
Catch ex As Exception
Debug.WriteLine(keyfileurl3 + vbNewLine + vbNewLine + ex.ToString)
@ -2328,7 +2435,7 @@ Public Class Main
Next
If Funimation_m3u8_final = Nothing Then
If Funimation_m3u8_final = Nothing And FunimationBackupm3u8 = Nothing Then
Me.Invoke(New Action(Function()
Me.Text = "Status: Resolution not found!"
@ -2338,12 +2445,11 @@ Public Class Main
ErrorDialog.ShowDialog()
Return Nothing
End Function))
ResoFunBackup = ResoBackString
For i As Integer = 0 To textLenght.Length - 1
If InStr(textLenght(i), "https") Then
If InStr(textLenght(i - 1), ResoBackString) Then
Dim CheckClient As New WebClient
CheckClient.Encoding = Encoding.UTF8
If WebbrowserCookie = Nothing Then
@ -2381,6 +2487,8 @@ Public Class Main
End If
End If
Next
ElseIf Funimation_m3u8_final = Nothing Then
Funimation_m3u8_final = FunimationBackupm3u8
Else
Me.Invoke(New Action(Function()
Me.Text = "Status: Resolution found!"
@ -2505,16 +2613,33 @@ Public Class Main
Next
Next
If Subs_in_srt.Count > 0 Then
Dim TempCount As Integer = UsedSubs.Count
If Funimation_srt = True Then
UsedSubs.Add(Subs_in_srt.Item(0) + " , " + SoftSubs2.Item(i).Replace(My.Resources.Funimation_Subtitle_String, "").Replace(My.Resources.Funimation_Subtitle_String2, ""))
ElseIf Subs_in_vtt.Count > 0 Then
End If
If Funimation_vtt = True Then
UsedSubs.Add(Subs_in_vtt.Item(0) + " , " + SoftSubs2.Item(i).Replace(My.Resources.Funimation_Subtitle_String, "").Replace(My.Resources.Funimation_Subtitle_String2, ""))
ElseIf Subs_in_dfxp.Count > 0 Then
End If
If Funimation_dfxp = True Then
UsedSubs.Add(Subs_in_dfxp.Item(0) + " , " + SoftSubs2.Item(i).Replace(My.Resources.Funimation_Subtitle_String, "").Replace(My.Resources.Funimation_Subtitle_String2, ""))
End If
If TempCount = UsedSubs.Count Then
If Subs_in_srt.Count > 0 Then
UsedSubs.Add(Subs_in_srt.Item(0) + " , " + SoftSubs2.Item(i).Replace(My.Resources.Funimation_Subtitle_String, "").Replace(My.Resources.Funimation_Subtitle_String2, ""))
ElseIf Subs_in_vtt.Count > 0 Then
UsedSubs.Add(Subs_in_vtt.Item(0) + " , " + SoftSubs2.Item(i).Replace(My.Resources.Funimation_Subtitle_String, "").Replace(My.Resources.Funimation_Subtitle_String2, ""))
ElseIf Subs_in_dfxp.Count > 0 Then
UsedSubs.Add(Subs_in_dfxp.Item(0) + " , " + SoftSubs2.Item(i).Replace(My.Resources.Funimation_Subtitle_String, "").Replace(My.Resources.Funimation_Subtitle_String2, ""))
End If
End If
Subs_in_srt.Clear()
Subs_in_vtt.Clear()
Subs_in_dfxp.Clear()
Next
End If
@ -2544,7 +2669,7 @@ Public Class Main
Else
For i As Integer = 0 To UsedSubs.Count - 1
LabelUpdate = "Status: downloading subtitle file"
LabelEpisode = SoftSubs2(i)
LabelEpisode = UsedSubs(i)
Dim SoftSub As String() = UsedSubs.Item(i).Split(New String() {" , "}, System.StringSplitOptions.RemoveEmptyEntries)
Dim SoftSub_3 As String = SoftSub(0).Replace("\/", "/")
Dim Subfile As String = SubsClient.DownloadString(SoftSub_3)
@ -2564,7 +2689,7 @@ Public Class Main
End If
Dim Pfad4 As String = Path.Combine(Path.GetDirectoryName(Pfad3), FN)
'MsgBox(Pfad4)
File.WriteAllText(Pfad4, str0, Encoding.UTF8)
File.WriteAllText(Pfad4, Subfile, Encoding.UTF8)
Pause(1)
Next

View File

@ -105,6 +105,12 @@ Partial Class einstellungen
Me.NumericUpDown1 = New System.Windows.Forms.NumericUpDown()
Me.TabControl1 = New MetroFramework.Controls.MetroTabControl()
Me.TabPage6 = New MetroFramework.Controls.MetroTabPage()
Me.GroupBox11 = New System.Windows.Forms.GroupBox()
Me.CB_srt = New System.Windows.Forms.CheckBox()
Me.CB_vtt = New System.Windows.Forms.CheckBox()
Me.CB_dfxp = New System.Windows.Forms.CheckBox()
Me.GroupBox10 = New System.Windows.Forms.GroupBox()
Me.Fun_Dub_Over = New System.Windows.Forms.ComboBox()
Me.GroupBox7 = New System.Windows.Forms.GroupBox()
Me.CB_Fun_HardSubs = New System.Windows.Forms.ComboBox()
Me.GroupBox9 = New System.Windows.Forms.GroupBox()
@ -128,8 +134,8 @@ Partial Class einstellungen
Me.Label5 = New System.Windows.Forms.Label()
Me.MetroStyleManager1 = New MetroFramework.Components.MetroStyleManager(Me.components)
Me.MetroStyleExtender1 = New MetroFramework.Components.MetroStyleExtender(Me.components)
Me.GroupBox10 = New System.Windows.Forms.GroupBox()
Me.Fun_Dub_Over = New System.Windows.Forms.ComboBox()
Me.GroupBox12 = New System.Windows.Forms.GroupBox()
Me.CR_Filename = New System.Windows.Forms.ComboBox()
CType(Me.pictureBox1, System.ComponentModel.ISupportInitialize).BeginInit()
CType(Me.pictureBox4, System.ComponentModel.ISupportInitialize).BeginInit()
Me.TabPage4.SuspendLayout()
@ -159,6 +165,8 @@ Partial Class einstellungen
CType(Me.NumericUpDown1, System.ComponentModel.ISupportInitialize).BeginInit()
Me.TabControl1.SuspendLayout()
Me.TabPage6.SuspendLayout()
Me.GroupBox11.SuspendLayout()
Me.GroupBox10.SuspendLayout()
Me.GroupBox7.SuspendLayout()
Me.GroupBox9.SuspendLayout()
Me.TabPage8.SuspendLayout()
@ -167,7 +175,7 @@ Partial Class einstellungen
CType(Me.PictureBox7, System.ComponentModel.ISupportInitialize).BeginInit()
Me.Panel2.SuspendLayout()
CType(Me.MetroStyleManager1, System.ComponentModel.ISupportInitialize).BeginInit()
Me.GroupBox10.SuspendLayout()
Me.GroupBox12.SuspendLayout()
Me.SuspendLayout()
'
'ToolTip1
@ -278,7 +286,7 @@ Partial Class einstellungen
'
Me.PictureBox2.Cursor = System.Windows.Forms.Cursors.Hand
Me.PictureBox2.Image = Global.Crunchyroll_Downloader.My.Resources.Resources.crdsettings_setUScookie_button
Me.PictureBox2.Location = New System.Drawing.Point(147, 259)
Me.PictureBox2.Location = New System.Drawing.Point(162, 362)
Me.PictureBox2.Name = "PictureBox2"
Me.PictureBox2.Size = New System.Drawing.Size(150, 30)
Me.PictureBox2.SizeMode = System.Windows.Forms.PictureBoxSizeMode.AutoSize
@ -596,6 +604,7 @@ Partial Class einstellungen
'TabPage2
'
Me.TabPage2.BackColor = System.Drawing.Color.FromArgb(CType(CType(243, Byte), Integer), CType(CType(243, Byte), Integer), CType(CType(243, Byte), Integer))
Me.TabPage2.Controls.Add(Me.GroupBox12)
Me.TabPage2.Controls.Add(Me.GroupBox4)
Me.TabPage2.Controls.Add(Me.GB_Sub_Path)
Me.TabPage2.Controls.Add(Me.CheckBox1)
@ -671,7 +680,7 @@ Partial Class einstellungen
Me.CheckBox1.BackColor = System.Drawing.Color.Transparent
Me.CheckBox1.Font = New System.Drawing.Font("Microsoft Sans Serif", 9.75!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.CheckBox1.ForeColor = System.Drawing.Color.Black
Me.CheckBox1.Location = New System.Drawing.Point(66, 210)
Me.CheckBox1.Location = New System.Drawing.Point(65, 285)
Me.CheckBox1.Name = "CheckBox1"
Me.CheckBox1.Size = New System.Drawing.Size(351, 20)
Me.CheckBox1.TabIndex = 6
@ -685,7 +694,7 @@ Partial Class einstellungen
Me.GroupBox2.Enabled = False
Me.GroupBox2.Font = New System.Drawing.Font("Arial", 9.75!)
Me.GroupBox2.ForeColor = System.Drawing.Color.Black
Me.GroupBox2.Location = New System.Drawing.Point(7, 230)
Me.GroupBox2.Location = New System.Drawing.Point(6, 311)
Me.GroupBox2.Name = "GroupBox2"
Me.GroupBox2.Size = New System.Drawing.Size(480, 63)
Me.GroupBox2.TabIndex = 40
@ -1088,7 +1097,7 @@ Partial Class einstellungen
Me.TabControl1.FontWeight = MetroFramework.MetroTabControlWeight.Regular
Me.TabControl1.Location = New System.Drawing.Point(22, 45)
Me.TabControl1.Name = "TabControl1"
Me.TabControl1.SelectedIndex = 3
Me.TabControl1.SelectedIndex = 1
Me.TabControl1.Size = New System.Drawing.Size(501, 500)
Me.TabControl1.TabIndex = 38
Me.TabControl1.UseSelectable = True
@ -1096,6 +1105,7 @@ Partial Class einstellungen
'TabPage6
'
Me.TabPage6.BackColor = System.Drawing.Color.FromArgb(CType(CType(243, Byte), Integer), CType(CType(243, Byte), Integer), CType(CType(243, Byte), Integer))
Me.TabPage6.Controls.Add(Me.GroupBox11)
Me.TabPage6.Controls.Add(Me.GroupBox10)
Me.TabPage6.Controls.Add(Me.GroupBox7)
Me.TabPage6.Controls.Add(Me.GroupBox9)
@ -1113,6 +1123,85 @@ Partial Class einstellungen
Me.TabPage6.VerticalScrollbarSize = 10
Me.TabPage6.Visible = False
'
'GroupBox11
'
Me.GroupBox11.BackColor = System.Drawing.Color.Transparent
Me.GroupBox11.Controls.Add(Me.CB_srt)
Me.GroupBox11.Controls.Add(Me.CB_vtt)
Me.GroupBox11.Controls.Add(Me.CB_dfxp)
Me.GroupBox11.Font = New System.Drawing.Font("Microsoft Sans Serif", 9.75!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.GroupBox11.Location = New System.Drawing.Point(6, 182)
Me.GroupBox11.Name = "GroupBox11"
Me.GroupBox11.Size = New System.Drawing.Size(475, 82)
Me.GroupBox11.TabIndex = 54
Me.GroupBox11.TabStop = False
Me.GroupBox11.Text = "Soft-Subtitle Format"
'
'CB_srt
'
Me.CB_srt.AutoSize = True
Me.CB_srt.Font = New System.Drawing.Font("Microsoft Sans Serif", 9.75!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.CB_srt.ForeColor = System.Drawing.Color.Black
Me.CB_srt.Location = New System.Drawing.Point(66, 41)
Me.CB_srt.Name = "CB_srt"
Me.CB_srt.Size = New System.Drawing.Size(41, 20)
Me.CB_srt.TabIndex = 0
Me.CB_srt.Text = "srt"
Me.CB_srt.UseVisualStyleBackColor = True
'
'CB_vtt
'
Me.CB_vtt.AutoSize = True
Me.CB_vtt.Font = New System.Drawing.Font("Microsoft Sans Serif", 9.75!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.CB_vtt.ForeColor = System.Drawing.Color.Black
Me.CB_vtt.Location = New System.Drawing.Point(188, 41)
Me.CB_vtt.Name = "CB_vtt"
Me.CB_vtt.Size = New System.Drawing.Size(40, 20)
Me.CB_vtt.TabIndex = 44
Me.CB_vtt.Text = "vtt"
Me.CB_vtt.UseVisualStyleBackColor = True
'
'CB_dfxp
'
Me.CB_dfxp.AutoSize = True
Me.CB_dfxp.Font = New System.Drawing.Font("Microsoft Sans Serif", 9.75!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.CB_dfxp.ForeColor = System.Drawing.Color.Black
Me.CB_dfxp.Location = New System.Drawing.Point(302, 41)
Me.CB_dfxp.Name = "CB_dfxp"
Me.CB_dfxp.Size = New System.Drawing.Size(52, 20)
Me.CB_dfxp.TabIndex = 45
Me.CB_dfxp.Text = "dfxp"
Me.CB_dfxp.UseVisualStyleBackColor = True
'
'GroupBox10
'
Me.GroupBox10.BackColor = System.Drawing.Color.Transparent
Me.GroupBox10.Controls.Add(Me.Fun_Dub_Over)
Me.GroupBox10.Font = New System.Drawing.Font("Arial", 9.75!)
Me.GroupBox10.ForeColor = System.Drawing.Color.Black
Me.GroupBox10.Location = New System.Drawing.Point(6, 270)
Me.GroupBox10.Name = "GroupBox10"
Me.GroupBox10.Size = New System.Drawing.Size(475, 69)
Me.GroupBox10.TabIndex = 55
Me.GroupBox10.TabStop = False
Me.GroupBox10.Text = "Funimation Dub"
'
'Fun_Dub_Over
'
Me.Fun_Dub_Over.DrawMode = System.Windows.Forms.DrawMode.OwnerDrawFixed
Me.Fun_Dub_Over.DropDownHeight = 250
Me.Fun_Dub_Over.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList
Me.Fun_Dub_Over.Font = New System.Drawing.Font("Microsoft Sans Serif", 9.75!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.Fun_Dub_Over.FormattingEnabled = True
Me.Fun_Dub_Over.IntegralHeight = False
Me.Fun_Dub_Over.ItemHeight = 16
Me.Fun_Dub_Over.Items.AddRange(New Object() {"Disabled", "english", "japanese", "portuguese(Brazil)", "spanish(Mexico)"})
Me.Fun_Dub_Over.Location = New System.Drawing.Point(69, 30)
Me.Fun_Dub_Over.Name = "Fun_Dub_Over"
Me.Fun_Dub_Over.Size = New System.Drawing.Size(326, 22)
Me.Fun_Dub_Over.Sorted = True
Me.Fun_Dub_Over.TabIndex = 33
'
'GroupBox7
'
Me.GroupBox7.BackColor = System.Drawing.Color.Transparent
@ -1383,34 +1472,33 @@ Partial Class einstellungen
'
Me.MetroStyleManager1.Owner = Nothing
'
'GroupBox10
'GroupBox12
'
Me.GroupBox10.BackColor = System.Drawing.Color.Transparent
Me.GroupBox10.Controls.Add(Me.Fun_Dub_Over)
Me.GroupBox10.Font = New System.Drawing.Font("Arial", 9.75!)
Me.GroupBox10.ForeColor = System.Drawing.Color.Black
Me.GroupBox10.Location = New System.Drawing.Point(6, 182)
Me.GroupBox10.Name = "GroupBox10"
Me.GroupBox10.Size = New System.Drawing.Size(478, 69)
Me.GroupBox10.TabIndex = 55
Me.GroupBox10.TabStop = False
Me.GroupBox10.Text = "Funimation Dub"
Me.GroupBox12.BackColor = System.Drawing.Color.Transparent
Me.GroupBox12.Controls.Add(Me.CR_Filename)
Me.GroupBox12.Font = New System.Drawing.Font("Arial", 9.75!)
Me.GroupBox12.ForeColor = System.Drawing.Color.Black
Me.GroupBox12.Location = New System.Drawing.Point(11, 195)
Me.GroupBox12.Name = "GroupBox12"
Me.GroupBox12.Size = New System.Drawing.Size(470, 63)
Me.GroupBox12.TabIndex = 53
Me.GroupBox12.TabStop = False
Me.GroupBox12.Text = "Filename"
'
'Fun_Dub_Over
'CR_Filename
'
Me.Fun_Dub_Over.DrawMode = System.Windows.Forms.DrawMode.OwnerDrawFixed
Me.Fun_Dub_Over.DropDownHeight = 250
Me.Fun_Dub_Over.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList
Me.Fun_Dub_Over.Font = New System.Drawing.Font("Microsoft Sans Serif", 9.75!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.Fun_Dub_Over.FormattingEnabled = True
Me.Fun_Dub_Over.IntegralHeight = False
Me.Fun_Dub_Over.ItemHeight = 16
Me.Fun_Dub_Over.Items.AddRange(New Object() {"Disabled", "english", "japanese", "portuguese(Brazil)", "spanish(Mexico)"})
Me.Fun_Dub_Over.Location = New System.Drawing.Point(69, 30)
Me.Fun_Dub_Over.Name = "Fun_Dub_Over"
Me.Fun_Dub_Over.Size = New System.Drawing.Size(326, 22)
Me.Fun_Dub_Over.Sorted = True
Me.Fun_Dub_Over.TabIndex = 33
Me.CR_Filename.DrawMode = System.Windows.Forms.DrawMode.OwnerDrawFixed
Me.CR_Filename.DropDownHeight = 250
Me.CR_Filename.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList
Me.CR_Filename.Font = New System.Drawing.Font("Microsoft Sans Serif", 9.75!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.CR_Filename.FormattingEnabled = True
Me.CR_Filename.IntegralHeight = False
Me.CR_Filename.ItemHeight = 16
Me.CR_Filename.Items.AddRange(New Object() {"[episode number]", "[episode name]", "[episode number] [episode name]"})
Me.CR_Filename.Location = New System.Drawing.Point(63, 25)
Me.CR_Filename.Name = "CR_Filename"
Me.CR_Filename.Size = New System.Drawing.Size(326, 22)
Me.CR_Filename.TabIndex = 34
'
'einstellungen
'
@ -1470,6 +1558,9 @@ Partial Class einstellungen
CType(Me.NumericUpDown1, System.ComponentModel.ISupportInitialize).EndInit()
Me.TabControl1.ResumeLayout(False)
Me.TabPage6.ResumeLayout(False)
Me.GroupBox11.ResumeLayout(False)
Me.GroupBox11.PerformLayout()
Me.GroupBox10.ResumeLayout(False)
Me.GroupBox7.ResumeLayout(False)
Me.GroupBox9.ResumeLayout(False)
Me.GroupBox9.PerformLayout()
@ -1480,7 +1571,7 @@ Partial Class einstellungen
CType(Me.PictureBox7, System.ComponentModel.ISupportInitialize).EndInit()
Me.Panel2.ResumeLayout(False)
CType(Me.MetroStyleManager1, System.ComponentModel.ISupportInitialize).EndInit()
Me.GroupBox10.ResumeLayout(False)
Me.GroupBox12.ResumeLayout(False)
Me.ResumeLayout(False)
Me.PerformLayout()
@ -1500,7 +1591,6 @@ Partial Class einstellungen
Public WithEvents comboBox4 As ComboBox
Public WithEvents ComboBox2 As ComboBox
Public WithEvents comboBox3 As ComboBox
Friend WithEvents CheckBox1 As CheckBox
Friend WithEvents GroupBox2 As GroupBox
Friend WithEvents Panel1 As Panel
Friend WithEvents MenuStrip1 As MenuStrip
@ -1592,4 +1682,11 @@ Partial Class einstellungen
Friend WithEvents GroupBox9 As GroupBox
Friend WithEvents GroupBox10 As GroupBox
Friend WithEvents Fun_Dub_Over As ComboBox
Friend WithEvents GroupBox11 As GroupBox
Friend WithEvents CB_srt As CheckBox
Friend WithEvents CB_vtt As CheckBox
Friend WithEvents CB_dfxp As CheckBox
Friend WithEvents CheckBox1 As CheckBox
Friend WithEvents GroupBox12 As GroupBox
Friend WithEvents CR_Filename As ComboBox
End Class

View File

@ -52,6 +52,15 @@ Public Class einstellungen
' RB_pt.Checked = True
'End If
Next
If Main.CR_NameMethode = 0 Then
CR_Filename.SelectedIndex = 0
ElseIf Main.CR_NameMethode = 1 Then
CR_Filename.SelectedIndex = 1
ElseIf Main.CR_NameMethode = 2 Then
CR_Filename.SelectedIndex = 2
Else
CR_Filename.SelectedIndex = 0
End If
Me.Location = New Point(Main.Location.X + Main.Width / 2 - Me.Width / 2, Main.Location.Y + Main.Height / 2 - Me.Height / 2)
Try
Me.Icon = My.Resources.icon
@ -66,7 +75,24 @@ Public Class einstellungen
HybridMode_CB.Checked = True
End If
'If Main.HardSubFunimation = True Then
If Main.Funimation_srt = True Then
CB_srt.Checked = True
Else
CB_srt.Checked = False
End If
If Main.Funimation_vtt = True Then
CB_vtt.Checked = True
Else
CB_vtt.Checked = False
End If
If Main.Funimation_dfxp = True Then
CB_dfxp.Checked = True
Else
CB_dfxp.Checked = False
End If
If Main.HardSubFunimation = "en" Then
CB_Fun_HardSubs.SelectedItem = "English"
@ -266,6 +292,19 @@ Public Class einstellungen
rk.SetValue("Sub", "None", RegistryValueKind.String)
End If
If CR_Filename.Text = "[episode number]" Then
Main.CR_NameMethode = 0
rk.SetValue("CR_NameMethode", 0, RegistryValueKind.String)
ElseIf CR_Filename.Text = "[episode name]" Then
Main.CR_NameMethode = 1
rk.SetValue("CR_NameMethode", 1, RegistryValueKind.String)
ElseIf CR_Filename.Text = "[episode number] [episode name]" Then
Main.CR_NameMethode = 2
rk.SetValue("CR_NameMethode", 2, RegistryValueKind.String)
End If
If MergeMP4.Checked = True Then
Main.MergeSubstoMP4 = True
rk.SetValue("MergeMP4", "1", RegistryValueKind.String)
@ -282,6 +321,29 @@ Public Class einstellungen
End If
#Region "funimation"
If CB_srt.Checked = True Then
Main.Funimation_srt = True
rk.SetValue("Funimation_srt", "1", RegistryValueKind.String)
Else
Main.Funimation_srt = False
rk.SetValue("Funimation_srt", "0", RegistryValueKind.String)
End If
If CB_vtt.Checked = True Then
Main.Funimation_vtt = True
rk.SetValue("Funimation_vtt", "1", RegistryValueKind.String)
Else
Main.Funimation_vtt = False
rk.SetValue("Funimation_vtt", "0", RegistryValueKind.String)
End If
If CB_dfxp.Checked = True Then
Main.Funimation_dfxp = True
rk.SetValue("Funimation_dfxp", "1", RegistryValueKind.String)
Else
Main.Funimation_dfxp = False
rk.SetValue("Funimation_dfxp", "0", RegistryValueKind.String)
End If
Main.DubFunimation = Fun_Dub_Over.SelectedItem.ToString
rk.SetValue("FunimationDub", Fun_Dub_Over.SelectedItem.ToString, RegistryValueKind.String)
@ -489,7 +551,7 @@ Public Class einstellungen
End Sub
Private Sub ComboBox1_DrawItem(sender As Object, e As DrawItemEventArgs) Handles ComboBox1.DrawItem, ComboBox2.DrawItem, comboBox3.DrawItem, comboBox4.DrawItem, CB_Fun_HardSubs.DrawItem, Fun_Dub_Over.DrawItem
Private Sub ComboBox1_DrawItem(sender As Object, e As DrawItemEventArgs) Handles ComboBox1.DrawItem, ComboBox2.DrawItem, comboBox3.DrawItem, comboBox4.DrawItem, CB_Fun_HardSubs.DrawItem, Fun_Dub_Over.DrawItem, CR_Filename.DrawItem
Dim CB As ComboBox = sender
CB.BackColor = Color.White
If e.Index >= 0 Then