diff --git a/.vs/Crunchyroll Downloader/v15/.suo b/.vs/Crunchyroll Downloader/v15/.suo index 400c77a..bb93bf3 100644 Binary files a/.vs/Crunchyroll Downloader/v15/.suo and b/.vs/Crunchyroll Downloader/v15/.suo differ diff --git a/.vs/Crunchyroll Downloader/v15/Server/sqlite3/storage.ide b/.vs/Crunchyroll Downloader/v15/Server/sqlite3/storage.ide index c9dc99e..2ab7c96 100644 Binary files a/.vs/Crunchyroll Downloader/v15/Server/sqlite3/storage.ide and b/.vs/Crunchyroll Downloader/v15/Server/sqlite3/storage.ide differ diff --git a/.vs/Crunchyroll Downloader/v15/Server/sqlite3/storage.ide-shm b/.vs/Crunchyroll Downloader/v15/Server/sqlite3/storage.ide-shm index 8795cdd..72ce694 100644 Binary files a/.vs/Crunchyroll Downloader/v15/Server/sqlite3/storage.ide-shm and b/.vs/Crunchyroll Downloader/v15/Server/sqlite3/storage.ide-shm differ diff --git a/.vs/Crunchyroll Downloader/v15/Server/sqlite3/storage.ide-wal b/.vs/Crunchyroll Downloader/v15/Server/sqlite3/storage.ide-wal index d1141d2..aa9f29c 100644 Binary files a/.vs/Crunchyroll Downloader/v15/Server/sqlite3/storage.ide-wal and b/.vs/Crunchyroll Downloader/v15/Server/sqlite3/storage.ide-wal differ diff --git a/Crunchyroll Downloader/CefSharp_Browser.vb b/Crunchyroll Downloader/CefSharp_Browser.vb index a009f76..7447730 100644 --- a/Crunchyroll Downloader/CefSharp_Browser.vb +++ b/Crunchyroll Downloader/CefSharp_Browser.vb @@ -113,11 +113,9 @@ Public Class CefSharp_Browser End If If WebBrowser1.Address = "about:blank" Or WebBrowser1.Address = Nothing Then - If Main.LoginOnly = "US_UnBlock" Then - WebBrowser1.Load("https://www.crunchyroll.com/login") - Else - WebBrowser1.Load(Main.Startseite) - End If + + WebBrowser1.Load(Main.Startseite) + End If Try Me.Icon = My.Resources.icon diff --git a/Crunchyroll Downloader/Crunchyroll Downloader.vbproj b/Crunchyroll Downloader/Crunchyroll Downloader.vbproj index f555c44..b916f65 100644 --- a/Crunchyroll Downloader/Crunchyroll Downloader.vbproj +++ b/Crunchyroll Downloader/Crunchyroll Downloader.vbproj @@ -152,6 +152,12 @@ + + ErrorBrowser.vb + + + Form + True @@ -220,6 +226,9 @@ + + ErrorBrowser.vb + network_scan.vb diff --git a/Crunchyroll Downloader/ErrorBrowser.Designer.vb b/Crunchyroll Downloader/ErrorBrowser.Designer.vb new file mode 100644 index 0000000..91bac8b --- /dev/null +++ b/Crunchyroll Downloader/ErrorBrowser.Designer.vb @@ -0,0 +1,51 @@ + _ +Partial Class ErrorBrowser + Inherits System.Windows.Forms.Form + + 'Das Formular überschreibt den Löschvorgang, um die Komponentenliste zu bereinigen. + _ + Protected Overrides Sub Dispose(ByVal disposing As Boolean) + Try + If disposing AndAlso components IsNot Nothing Then + components.Dispose() + End If + Finally + MyBase.Dispose(disposing) + End Try + End Sub + + 'Wird vom Windows Form-Designer benötigt. + Private components As System.ComponentModel.IContainer + + 'Hinweis: Die folgende Prozedur ist für den Windows Form-Designer erforderlich. + 'Das Bearbeiten ist mit dem Windows Form-Designer möglich. + 'Das Bearbeiten mit dem Code-Editor ist nicht möglich. + _ + Private Sub InitializeComponent() + Me.ChromiumWebBrowser1 = New CefSharp.WinForms.ChromiumWebBrowser() + Me.SuspendLayout() + ' + 'ChromiumWebBrowser1 + ' + Me.ChromiumWebBrowser1.ActivateBrowserOnCreation = False + 'TODO: Ausnahme "Ungültiger primitiver Typ: System.IntPtr. Verwenden Sie CodeObjectCreateExpression." beim Generieren des Codes für "". + Me.ChromiumWebBrowser1.Dock = System.Windows.Forms.DockStyle.Fill + Me.ChromiumWebBrowser1.Location = New System.Drawing.Point(0, 0) + Me.ChromiumWebBrowser1.Name = "ChromiumWebBrowser1" + Me.ChromiumWebBrowser1.Size = New System.Drawing.Size(911, 569) + Me.ChromiumWebBrowser1.TabIndex = 0 + ' + 'ErrorBrowser + ' + Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!) + Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font + Me.ClientSize = New System.Drawing.Size(911, 569) + Me.Controls.Add(Me.ChromiumWebBrowser1) + Me.Name = "ErrorBrowser" + Me.Text = "ErrorBrowser" + Me.ResumeLayout(False) + + End Sub + + Friend WithEvents ChromiumWebBrowser1 As CefSharp.WinForms.ChromiumWebBrowser +End Class diff --git a/Crunchyroll Downloader/ErrorBrowser.resx b/Crunchyroll Downloader/ErrorBrowser.resx new file mode 100644 index 0000000..1af7de1 --- /dev/null +++ b/Crunchyroll Downloader/ErrorBrowser.resx @@ -0,0 +1,120 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + \ No newline at end of file diff --git a/Crunchyroll Downloader/ErrorBrowser.vb b/Crunchyroll Downloader/ErrorBrowser.vb new file mode 100644 index 0000000..faf4703 --- /dev/null +++ b/Crunchyroll Downloader/ErrorBrowser.vb @@ -0,0 +1,57 @@ +Imports CefSharp + +Public Class ErrorBrowser + + + Private Sub ChromiumWebBrowser1_FrameLoadEnd(sender As Object, e As FrameLoadEndEventArgs) Handles ChromiumWebBrowser1.FrameLoadEnd + If e.Frame.IsMain Then + + + + + GetHTML() + + End If + End Sub + + Async Sub GetHTML() + Try + + Dim HTML As String = Await ChromiumWebBrowser1.GetSourceAsync + Debug.WriteLine("got error browser html") + Me.Invoke(New Action(Function() As Object + + ProcessFallbackHTML(HTML, ChromiumWebBrowser1.Address) + 'If Main.UserBowser = False Then + ' Me.Close() + 'End If + Return Nothing + End Function)) + + Catch ex As Exception + + End Try + End Sub + + Public Sub ProcessFallbackHTML(ByVal document As String, ByVal Address As String) + Dim localHTML As String = document + Debug.WriteLine(Date.Now.ToString + "." + Date.Now.Millisecond.ToString) + Debug.WriteLine(Address) + + If CBool(InStr(Address, "https://www.funimation.com/api/showexperience/")) Then + + Main.ErrorBrowserBackString = localHTML.Replace("", "").Replace("", "").Replace("
", "").Replace("
", "").Replace("", "").Replace("
", "") '
+
+            Me.Close()
+
+        End If
+
+    End Sub
+
+    Private Sub ErrorBrowser_Load(sender As Object, e As EventArgs) Handles MyBase.Load
+        Me.Location = New Point(-10000, -10000)
+        If Main.ErrorBrowserString = "Funimation_showexperience" Then
+            ChromiumWebBrowser1.Load(Main.ErrorBrowserUrl)
+        End If
+    End Sub
+End Class
\ No newline at end of file
diff --git a/Crunchyroll Downloader/Main.vb b/Crunchyroll Downloader/Main.vb
index 7520a5e..0f637e9 100644
--- a/Crunchyroll Downloader/Main.vb	
+++ b/Crunchyroll Downloader/Main.vb	
@@ -84,6 +84,9 @@ Public Class Main
     Public NonCR_URL As String = Nothing
     Public DlSoftSubsRDY As Boolean = True
     Public DialogTaskString As String
+    Public ErrorBrowserString As String
+    Public ErrorBrowserUrl As String
+    Public ErrorBrowserBackString As String
     Public UserCloseDialog As Boolean = False
     Dim Aktuell As String
     Dim Gesamt As String
@@ -3915,10 +3918,9 @@ Public Class Main
                 ElseIf Not SystemWebBrowserCookie = Nothing Then
                     client0.Headers.Add(HttpRequestHeader.Cookie, SystemWebBrowserCookie)
                 End If
-
                 Dim str0 As String = client0.DownloadString("https://www.funimation.com/api/showexperience/" + Player_ID2(0) + "/?pinst_id=fzQc9p9f")
-                'MsgBox("https://www.funimation.com/api/showexperience/" + Player_ID2(0) + "/?pinst_id=fzQc9p9f")
-                'MsgBox(str0)
+
+
                 Dim Funimation_m3u8() As String = str0.Split(New String() {My.Resources.Funimation_src_string}, System.StringSplitOptions.RemoveEmptyEntries)
                 Dim Funimation_m3u8_Main As String = Nothing
                 For i As Integer = 0 To Funimation_m3u8.Count - 1
@@ -5123,18 +5125,44 @@ Public Class Main
                                          Return Nothing
                                      End Function))
 
+                Dim showexperience As String = Nothing
+                Try
+                    'Throw New System.Exception("Test")
+                    Using client As New WebClient()
+                        client.Encoding = System.Text.Encoding.UTF8
+                        client.Headers.Add(My.Resources.ffmpeg_user_agend.Replace(Chr(34), ""))
+                        showexperience = client.DownloadString("https://www.funimation.com/api/showexperience/" + ExperienceID + "/?pinst_id=fzQc9p9f")
 
 
-                If Not WebbrowserCookie = Nothing Then
-                    client0.Headers.Add(HttpRequestHeader.Cookie, WebbrowserCookie)
-                ElseIf Not SystemWebBrowserCookie = Nothing Then
-                    client0.Headers.Add(HttpRequestHeader.Cookie, SystemWebBrowserCookie)
-                End If
+                    End Using
+                Catch ex As Exception
+                    Debug.WriteLine("error- getting funimation showexperience data")
+                    Me.Invoke(New Action(Function() As Object
+                                             'Me.Text = "Status: Resolution not found!"
+                                             'Me.Invalidate()
+                                             ErrorBrowserString = "Funimation_showexperience"
+                                             ErrorBrowserUrl = "https://www.funimation.com/api/showexperience/" + ExperienceID + "/?pinst_id=fzQc9p9f"
+                                             ErrorBrowser.ShowDialog()
+                                             Return Nothing
+                                         End Function))
+                    showexperience = ErrorBrowserBackString
 
-                Dim str0 As String = client0.DownloadString("https://www.funimation.com/api/showexperience/" + ExperienceID + "/?pinst_id=fzQc9p9f")
-                'MsgBox("https://www.funimation.com/api/showexperience/" + Player_ID2(0) + "/?pinst_id=fzQc9p9f")
-                'MsgBox(str0)
-                Dim Funimation_m3u8() As String = str0.Split(New String() {My.Resources.Funimation_src_string}, System.StringSplitOptions.RemoveEmptyEntries)
+                End Try
+
+
+
+
+                'If Not WebbrowserCookie = Nothing Then
+                '    client0.Headers.Add(HttpRequestHeader.Cookie, WebbrowserCookie)
+                'ElseIf Not SystemWebBrowserCookie = Nothing Then
+                '    client0.Headers.Add(HttpRequestHeader.Cookie, SystemWebBrowserCookie)
+                'End If
+
+                'Dim str0 As String = client0.DownloadString("")
+                ''MsgBox("https://www.funimation.com/api/showexperience/" + Player_ID2(0) + "/?pinst_id=fzQc9p9f")
+                ''MsgBox(str0)
+
+                Dim Funimation_m3u8() As String = showexperience.Split(New String() {My.Resources.Funimation_src_string}, System.StringSplitOptions.RemoveEmptyEntries)
                 Dim Funimation_m3u8_Main As String = Nothing
                 For i As Integer = 0 To Funimation_m3u8.Count - 1
                     If CBool(InStr(Funimation_m3u8(i), "m3u8?")) Then
@@ -5145,7 +5173,7 @@ Public Class Main
                 Next
                 If Funimation_m3u8_Main = Nothing Then
 
-                    If MessageBox.Show("No media found in:" + vbNewLine + str0, "No media", MessageBoxButtons.RetryCancel) = DialogResult.Retry Then
+                    If MessageBox.Show("No media found in:" + vbNewLine + showexperience, "No media", MessageBoxButtons.RetryCancel) = DialogResult.Retry Then
                         Me.Invoke(New Action(Function() As Object
                                                  Navigate(WebbrowserURL)
                                                  Try
diff --git a/Crunchyroll Downloader/MaxPath.resx b/Crunchyroll Downloader/MaxPath.resx
new file mode 100644
index 0000000..1af7de1
--- /dev/null
+++ b/Crunchyroll Downloader/MaxPath.resx	
@@ -0,0 +1,120 @@
+
+
+  
+  
+    
+    
+      
+        
+          
+            
+              
+                
+              
+              
+              
+              
+              
+            
+          
+          
+            
+              
+              
+            
+          
+          
+            
+              
+                
+                
+              
+              
+              
+              
+              
+            
+          
+          
+            
+              
+                
+              
+              
+            
+          
+        
+      
+    
+  
+  
+    text/microsoft-resx
+  
+  
+    2.0
+  
+  
+    System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+  
+  
+    System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+  
+
\ No newline at end of file
diff --git a/Crunchyroll Downloader/bin/x64/Debug/Crunchyroll Downloader.exe b/Crunchyroll Downloader/bin/x64/Debug/Crunchyroll Downloader.exe
index 1c0a04b..c4097ac 100644
Binary files a/Crunchyroll Downloader/bin/x64/Debug/Crunchyroll Downloader.exe and b/Crunchyroll Downloader/bin/x64/Debug/Crunchyroll Downloader.exe differ
diff --git a/Crunchyroll Downloader/bin/x64/Debug/Crunchyroll Downloader.pdb b/Crunchyroll Downloader/bin/x64/Debug/Crunchyroll Downloader.pdb
index 2864b02..c14425a 100644
Binary files a/Crunchyroll Downloader/bin/x64/Debug/Crunchyroll Downloader.pdb and b/Crunchyroll Downloader/bin/x64/Debug/Crunchyroll Downloader.pdb differ
diff --git a/Crunchyroll Downloader/obj/x64/Debug/Crunchyroll Downloader.exe b/Crunchyroll Downloader/obj/x64/Debug/Crunchyroll Downloader.exe
index 1c0a04b..c4097ac 100644
Binary files a/Crunchyroll Downloader/obj/x64/Debug/Crunchyroll Downloader.exe and b/Crunchyroll Downloader/obj/x64/Debug/Crunchyroll Downloader.exe differ
diff --git a/Crunchyroll Downloader/obj/x64/Debug/Crunchyroll Downloader.pdb b/Crunchyroll Downloader/obj/x64/Debug/Crunchyroll Downloader.pdb
index 2864b02..c14425a 100644
Binary files a/Crunchyroll Downloader/obj/x64/Debug/Crunchyroll Downloader.pdb and b/Crunchyroll Downloader/obj/x64/Debug/Crunchyroll Downloader.pdb differ
diff --git a/Crunchyroll Downloader/obj/x64/Debug/Crunchyroll Downloader.vbproj.CoreCompileInputs.cache b/Crunchyroll Downloader/obj/x64/Debug/Crunchyroll Downloader.vbproj.CoreCompileInputs.cache
index 0150316..4b7af1f 100644
--- a/Crunchyroll Downloader/obj/x64/Debug/Crunchyroll Downloader.vbproj.CoreCompileInputs.cache	
+++ b/Crunchyroll Downloader/obj/x64/Debug/Crunchyroll Downloader.vbproj.CoreCompileInputs.cache	
@@ -1 +1 @@
-9d0b0f58f3e3e0b7bdc86a742adab0e96e9318e5
+6f9417ce7e694fa1e780dfd866bafe4f10e58047
diff --git a/Crunchyroll Downloader/obj/x64/Debug/Crunchyroll Downloader.vbproj.FileListAbsolute.txt b/Crunchyroll Downloader/obj/x64/Debug/Crunchyroll Downloader.vbproj.FileListAbsolute.txt
index 584edda..3043640 100644
--- a/Crunchyroll Downloader/obj/x64/Debug/Crunchyroll Downloader.vbproj.FileListAbsolute.txt	
+++ b/Crunchyroll Downloader/obj/x64/Debug/Crunchyroll Downloader.vbproj.FileListAbsolute.txt	
@@ -106,3 +106,4 @@ D:\Projecte\Crunchyroll Downloader - v3.0-final\Crunchyroll-Downloader-v3.0 - Ce
 D:\Projecte\Crunchyroll Downloader - v3.0-final\Crunchyroll-Downloader-v3.0 - CefSharp\Crunchyroll Downloader\obj\x64\Debug\Crunchyroll Downloader.pdb
 D:\Projecte\Crunchyroll Downloader - v3.0-final\Crunchyroll-Downloader-v3.0 - CefSharp\Crunchyroll Downloader\obj\x64\Debug\Crunchyroll Downloader.vbprojAssemblyReference.cache
 D:\Projecte\Crunchyroll Downloader - v3.0-final\Crunchyroll-Downloader-v3.0 - CefSharp\Crunchyroll Downloader\bin\x64\Debug\libcef.dll
+D:\Projecte\Crunchyroll Downloader - v3.0-final\Crunchyroll-Downloader-v3.0 - CefSharp\Crunchyroll Downloader\obj\x64\Debug\Crunchyroll_Downloader.ErrorBrowser.resources
diff --git a/Crunchyroll Downloader/obj/x64/Debug/Crunchyroll Downloader.vbproj.GenerateResource.cache b/Crunchyroll Downloader/obj/x64/Debug/Crunchyroll Downloader.vbproj.GenerateResource.cache
index 7389bc8..fa66dc9 100644
Binary files a/Crunchyroll Downloader/obj/x64/Debug/Crunchyroll Downloader.vbproj.GenerateResource.cache and b/Crunchyroll Downloader/obj/x64/Debug/Crunchyroll Downloader.vbproj.GenerateResource.cache differ
diff --git a/Crunchyroll Downloader/obj/x64/Debug/Crunchyroll_Downloader.ErrorBrowser.resources b/Crunchyroll Downloader/obj/x64/Debug/Crunchyroll_Downloader.ErrorBrowser.resources
new file mode 100644
index 0000000..6c05a97
Binary files /dev/null and b/Crunchyroll Downloader/obj/x64/Debug/Crunchyroll_Downloader.ErrorBrowser.resources differ