From 655794fd1751f9890cb6ed6a3099da8a0437d399 Mon Sep 17 00:00:00 2001 From: shoaib11120 Date: Wed, 29 Dec 2021 18:09:31 +0530 Subject: [PATCH] Removed unwanted infos from log --- stardew-access/ScreenReader.cs | 23 +++++++---------------- 1 file changed, 7 insertions(+), 16 deletions(-) diff --git a/stardew-access/ScreenReader.cs b/stardew-access/ScreenReader.cs index c3ffd3c..158779e 100644 --- a/stardew-access/ScreenReader.cs +++ b/stardew-access/ScreenReader.cs @@ -19,39 +19,30 @@ namespace stardew_access { nvdaOutput = new NvdaOutput(); } - catch (Exception ex) - { - MainClass.monitor.Log($"Error initializing NVDA:\n{ex.StackTrace}", LogLevel.Info); - } + catch (Exception) { } // Initialize JAWS try { jawsOutput = new JawsOutput(); } - catch (Exception ex) - { - MainClass.monitor.Log($"Error initializing JAWS:\n{ex.StackTrace}", LogLevel.Info); - } + catch (Exception) { } // Initialize SAPI try { sapiOutput = new SapiOutput(); } - catch (Exception ex) - { - MainClass.monitor.Log($"Error initializing SAPI:\n{ex.StackTrace}", LogLevel.Info); - } + catch (Exception){ } if (nvdaOutput != null && nvdaOutput.IsAvailable()) screenReader = nvdaOutput; - - if (jawsOutput != null && jawsOutput.IsAvailable()) + else if (jawsOutput != null && jawsOutput.IsAvailable()) screenReader = jawsOutput; - - if (sapiOutput != null && sapiOutput.IsAvailable()) + else if (sapiOutput != null && sapiOutput.IsAvailable()) screenReader = sapiOutput; + else + MainClass.monitor.Log($"Unable to load any screen reader!", LogLevel.Error); } public static void say(string text, bool interrupt)