mirror of
https://github.com/rosenbjerg/FFMpegCore.git
synced 2024-11-10 08:34:12 +01:00
Fixed GetText to pleasure the unit test
This commit is contained in:
parent
1b2af5fd1f
commit
c05337562c
1 changed files with 8 additions and 2 deletions
|
@ -23,13 +23,19 @@ private FFMpegArguments() { }
|
||||||
private string GetText()
|
private string GetText()
|
||||||
{
|
{
|
||||||
var sb = new StringBuilder();
|
var sb = new StringBuilder();
|
||||||
|
var appendSpace = false;
|
||||||
|
|
||||||
foreach (var arg in _globalArguments.Arguments.Concat(Arguments))
|
foreach (var arg in _globalArguments.Arguments.Concat(Arguments))
|
||||||
{
|
{
|
||||||
if (sb.Length != 0)
|
if (appendSpace)
|
||||||
{
|
{
|
||||||
sb.Append(' ');
|
sb.Append(' ');
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
appendSpace = true;
|
||||||
|
}
|
||||||
|
|
||||||
sb.Append(arg is IDynamicArgument dynArg ? dynArg.GetText(sb) : arg.Text);
|
sb.Append(arg is IDynamicArgument dynArg ? dynArg.GetText(sb) : arg.Text);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue