Kaynağa Gözat

Merge pull request #7339 from MoYuan-CN/main

允许通过 UrlScheme 打开 Preview 基岩版
龙腾猫跃 1 yıl önce
ebeveyn
işleme
e5dccf3a13

+ 1 - 1
Plain Craft Launcher 2/Modules/Base/ModBase.vb

@@ -2539,7 +2539,7 @@ NextElement:
     ''' </summary>
     ''' </summary>
     Public Sub OpenWebsite(Url As String)
     Public Sub OpenWebsite(Url As String)
         Try
         Try
-            If Not Url.StartsWithF("http", True) AndAlso Not Url.StartsWithF("minecraft://", True) Then
+            If Not Url.StartsWithF("http", True) AndAlso Not Url.StartsWithF("minecraft://", True) AndAlso Not Url.StartsWithF("minecraft-preview://", True) Then
                 Throw New Exception(Url & " 不是一个有效的网址,它必须以 http 开头!")
                 Throw New Exception(Url & " 不是一个有效的网址,它必须以 http 开头!")
             End If
             End If
             Log("[System] 正在打开网页:" & Url)
             Log("[System] 正在打开网页:" & Url)