Skip to content

Commit

Permalink
开启下载完成后混流时 自动启用二进制合并
Browse files Browse the repository at this point in the history
  • Loading branch information
nilaoda committed Jun 18, 2023
1 parent c05dbab commit 4c60819
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/N_m3u8DL-RE.Common/Resource/ResString.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ public class ResString
public static string autoBinaryMerge3 { get => GetText("autoBinaryMerge3"); }
public static string autoBinaryMerge4 { get => GetText("autoBinaryMerge4"); }
public static string autoBinaryMerge5 { get => GetText("autoBinaryMerge5"); }
public static string autoBinaryMerge6 { get => GetText("autoBinaryMerge6"); }
public static string badM3u8 { get => GetText("badM3u8"); }
public static string binaryMerge { get => GetText("binaryMerge"); }
public static string checkingLast { get => GetText("checkingLast"); }
Expand Down
6 changes: 6 additions & 0 deletions src/N_m3u8DL-RE.Common/Resource/StaticText.cs
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,12 @@ internal class StaticText
zhTW: "檢測到杜比視界內容,混流功能已禁用",
enUS: "Dolby Vision content is detected, mux after done is automatically disabled"
),
["autoBinaryMerge6"] = new TextContainer
(
zhCN: "你已开启下载完成后混流,自动开启二进制合并",
zhTW: "你已開啟下載完成後混流,自動開啟二進制合併",
enUS: "MuxAfterDone is detected, binary merging is automatically enabled"
),
["badM3u8"] = new TextContainer
(
zhCN: "错误的m3u8",
Expand Down
7 changes: 7 additions & 0 deletions src/N_m3u8DL-RE/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -319,6 +319,13 @@ static async Task DoWorkAsync(MyOption option)

Logger.InfoMarkUp(ResString.saveName + $"[deepskyblue1]{option.SaveName.EscapeMarkup()}[/]");

//开始MuxAfterDone后自动使用二进制版
if (!option.BinaryMerge && option.MuxAfterDone)
{
option.BinaryMerge = true;
Logger.WarnMarkUp($"[darkorange3_1]{ResString.autoBinaryMerge6}[/]");
}

//下载配置
var downloadConfig = new DownloaderConfig()
{
Expand Down

0 comments on commit 4c60819

Please sign in to comment.