mirror of
https://github.com/PepperDash/Essentials.git
synced 2026-02-07 16:55:04 +00:00
Adds configuratble property for current audio/video output text. Defaults to "".
This commit is contained in:
@@ -66,6 +66,11 @@ namespace PepperDash.Essentials.DM
|
||||
public const int RouteOffTime = 500;
|
||||
Dictionary<PortNumberType, CTimer> RouteOffTimers = new Dictionary<PortNumberType, CTimer>();
|
||||
|
||||
/// <summary>
|
||||
/// Text that represents when an output has no source routed to it
|
||||
/// </summary>
|
||||
public string NoRouteText = "";
|
||||
|
||||
/// <summary>
|
||||
/// Factory method to create a new chassis controller from config data. Limited to 8x8 right now
|
||||
/// </summary>
|
||||
@@ -128,6 +133,10 @@ namespace PepperDash.Essentials.DM
|
||||
|
||||
controller.InputNames = properties.InputNames;
|
||||
controller.OutputNames = properties.OutputNames;
|
||||
|
||||
if (!string.IsNullOrEmpty(properties.NoRouteText))
|
||||
controller.NoRouteText = properties.NoRouteText;
|
||||
|
||||
controller.PropertiesConfig = properties;
|
||||
return controller;
|
||||
}
|
||||
@@ -217,7 +226,7 @@ namespace PepperDash.Essentials.DM
|
||||
}
|
||||
else
|
||||
{
|
||||
return "";
|
||||
return NoRouteText;
|
||||
}
|
||||
});
|
||||
OutputAudioRouteNameFeedbacks[tempX] = new StringFeedback(() =>
|
||||
@@ -228,7 +237,7 @@ namespace PepperDash.Essentials.DM
|
||||
}
|
||||
else
|
||||
{
|
||||
return "";
|
||||
return NoRouteText;
|
||||
|
||||
}
|
||||
});
|
||||
|
||||
@@ -48,6 +48,11 @@ namespace PepperDash.Essentials.DM
|
||||
public const int RouteOffTime = 500;
|
||||
Dictionary<PortNumberType, CTimer> RouteOffTimers = new Dictionary<PortNumberType, CTimer>();
|
||||
|
||||
/// <summary>
|
||||
/// Text that represents when an output has no source routed to it
|
||||
/// </summary>
|
||||
public string NoRouteText = "";
|
||||
|
||||
public static DmpsRoutingController GetDmpsRoutingController(string key, string name,
|
||||
DmpsRoutingPropertiesConfig properties)
|
||||
{
|
||||
@@ -67,6 +72,9 @@ namespace PepperDash.Essentials.DM
|
||||
controller.InputNames = properties.InputNames;
|
||||
controller.OutputNames = properties.OutputNames;
|
||||
|
||||
if (!string.IsNullOrEmpty(properties.NoRouteText))
|
||||
controller.NoRouteText = properties.NoRouteText;
|
||||
|
||||
return controller;
|
||||
|
||||
}
|
||||
@@ -191,7 +199,7 @@ namespace PepperDash.Essentials.DM
|
||||
}
|
||||
else
|
||||
{
|
||||
return "";
|
||||
return NoRouteText;
|
||||
}
|
||||
});
|
||||
OutputAudioRouteNameFeedbacks[outputCard.Number] = new StringFeedback(() =>
|
||||
@@ -202,7 +210,7 @@ namespace PepperDash.Essentials.DM
|
||||
}
|
||||
else
|
||||
{
|
||||
return "";
|
||||
return NoRouteText;
|
||||
|
||||
}
|
||||
});
|
||||
|
||||
@@ -32,6 +32,9 @@ namespace PepperDash.Essentials.DM.Config
|
||||
[JsonProperty("outputNames")]
|
||||
public Dictionary<uint, string> OutputNames { get; set; }
|
||||
|
||||
[JsonProperty("noRouteText")]
|
||||
public string NoRouteText { get; set; }
|
||||
|
||||
[JsonProperty("inputSlotSupportsHdcp2")]
|
||||
public Dictionary<uint, bool> InputSlotSupportsHdcp2 { get; set; }
|
||||
|
||||
|
||||
@@ -20,6 +20,9 @@ namespace PepperDash.Essentials.DM.Config
|
||||
[JsonProperty("outputNames")]
|
||||
public Dictionary<uint, string> OutputNames { get; set; }
|
||||
|
||||
[JsonProperty("noRouteText")]
|
||||
public string NoRouteText { get; set; }
|
||||
|
||||
public DmpsRoutingPropertiesConfig()
|
||||
{
|
||||
InputNames = new Dictionary<uint, string>();
|
||||
|
||||
Reference in New Issue
Block a user