Support for encoding mode and thumbfast and some other new features and improvements

This commit is contained in:
stax76
2023-12-10 16:56:51 +01:00
parent 60dfbee16d
commit b3877492dd
12 changed files with 254 additions and 131 deletions

View File

@@ -6,16 +6,18 @@ namespace MpvNet;
public class InputConf
{
string? _content;
string? _path;
public InputConf(string path) { Path = path; }
public string Path { get; }
public string Content { get; set; } = "";
public string Content
{
get => _content ??= FileHelp.ReadTextFile(Path);
set => _content = value;
public string Path {
get => _path ?? "";
set {
_path = value;
Content = File.Exists(_path) ? FileHelp.ReadTextFile(_path) : "";
}
}
public bool HasMenu => Content.Contains("#menu:") || Content.Contains("#! ");