public void SceneAtLevel(bool atLevel) { if (this._atLevel != atLevel) { this._atLevel = atLevel; var hub = MessageHub.Instance; SceneAtLevelEvent atLevelEvent = new SceneAtLevelEvent(this, atLevel); //CrestronConsole.PrintLine("Sending Scene At Level"); hub.Publish <SceneAtLevelEvent>(atLevelEvent); } }
public void ProcessSceneAtLevelEvent(SceneAtLevelEvent sceneEvent) { if (pagedScenes != null) { var index = pagedScenes.FindIndex(x => x.SceneID == sceneEvent.Scene.SceneID); if (index >= 0) { if (sceneEvent.AtLevel) { this._view.SetSceneOn((uint)index); } else { this._view.SetSceneOff((uint)index); } } } }