From f85896e9479661cb87fbc135b88fb3ef3aea599f Mon Sep 17 00:00:00 2001 From: Drew Tingen Date: Sun, 24 Feb 2019 16:19:03 -0500 Subject: [PATCH] fix: PrintLine raises OnConoslePrint, Crestron Console Response uses PrintLine, Better environment checks --- ICD.Common.Utils/IcdConsole.cs | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/ICD.Common.Utils/IcdConsole.cs b/ICD.Common.Utils/IcdConsole.cs index 1f58b6b..15c0136 100644 --- a/ICD.Common.Utils/IcdConsole.cs +++ b/ICD.Common.Utils/IcdConsole.cs @@ -55,22 +55,24 @@ namespace ICD.Common.Utils } catch (NotSupportedException) { - Print(message); + PrintLine(message); } return; } #endif - Print(message); + PrintLine(message); } public static void PrintLine(string message) { #if SIMPLSHARP - CrestronConsole.PrintLine(message); + if (IcdEnvironment.RuntimeEnvironment != IcdEnvironment.eRuntimeEnvironment.SimplSharpProMono) + CrestronConsole.PrintLine(message); #else Console.WriteLine(message); #endif + OnConsolePrint.Raise(null, new StringEventArgs(message + IcdEnvironment.NewLine)); } public static void PrintLine(string message, params object[] args)