resolves #176 - Added IHasBasicTriListWithSmartObject to DgeController

This commit is contained in:
Trevor Payne
2020-05-12 13:28:55 -05:00
parent 7caef808b7
commit fd3e8d81f8

View File

@@ -11,26 +11,29 @@ using Newtonsoft.Json;
using PepperDash.Core; using PepperDash.Core;
using PepperDash.Essentials.Core; using PepperDash.Essentials.Core;
using PepperDash.Essentials.Core.Config; using PepperDash.Essentials.Core.Config;
using Crestron.SimplSharpPro.DeviceSupport;
namespace PepperDash.Essentials.DM.Endpoints.DGEs namespace PepperDash.Essentials.DM.Endpoints.DGEs
{ {
/// <summary> /// <summary>
/// Wrapper class for DGE-100 and DM-DGE-200-C /// Wrapper class for DGE-100 and DM-DGE-200-C
/// </summary> /// </summary>
public class DgeController : CrestronGenericBaseDevice, IComPorts, IIROutputPorts public class DgeController : CrestronGenericBaseDevice, IComPorts, IIROutputPorts, IHasBasicTriListWithSmartObject
{ {
public Dge100 DigitalGraphicsEngine { get; private set; } private readonly Dge100 _dge;
public DeviceConfig DeviceConfig { get; private set; } public BasicTriListWithSmartObject Panel { get { return _dge; } }
public DeviceConfig _dc;
CrestronTouchpanelPropertiesConfig PropertiesConfig; CrestronTouchpanelPropertiesConfig PropertiesConfig;
public DgeController(string key, string name, Dge100 device, DeviceConfig dc, CrestronTouchpanelPropertiesConfig props) public DgeController(string key, string name, Dge100 device, DeviceConfig dc, CrestronTouchpanelPropertiesConfig props)
:base(key, name, device) :base(key, name, device)
{ {
DigitalGraphicsEngine = device; _dge = device;
DeviceConfig = dc; _dc = dc;
PropertiesConfig = props; PropertiesConfig = props;
} }
@@ -39,12 +42,12 @@ namespace PepperDash.Essentials.DM.Endpoints.DGEs
public CrestronCollection<ComPort> ComPorts public CrestronCollection<ComPort> ComPorts
{ {
get { return DigitalGraphicsEngine.ComPorts; } get { return _dge.ComPorts; }
} }
public int NumberOfComPorts public int NumberOfComPorts
{ {
get { return DigitalGraphicsEngine.NumberOfComPorts; } get { return _dge.NumberOfComPorts; }
} }
#endregion #endregion
@@ -53,12 +56,12 @@ namespace PepperDash.Essentials.DM.Endpoints.DGEs
public CrestronCollection<IROutputPort> IROutputPorts public CrestronCollection<IROutputPort> IROutputPorts
{ {
get { return DigitalGraphicsEngine.IROutputPorts; } get { return _dge.IROutputPorts; }
} }
public int NumberOfIROutputPorts public int NumberOfIROutputPorts
{ {
get { return DigitalGraphicsEngine.NumberOfIROutputPorts; } get { return _dge.NumberOfIROutputPorts; }
} }
#endregion #endregion