private static void HandleLogReceived(string condition, string stackTrace, LogType type)
        {
            Color logColor = ColorForLogType(type);

            bufferedLines_.Enqueue(RichTextUtil.WrapWithColorTag(condition, logColor));

            if (bufferedLines_.Count >= kBufferLimit || bufferedLines_.Sum(l => l.Length) >= kCharacterLimit)
            {
                bufferedLines_.Dequeue();
            }
            OnLogUpdated.Invoke();
        }
Exemple #2
0
 public static void LogLine(string value)
 {
     logBuilder.AppendLine(value);
     System.Diagnostics.Debug.WriteLine(value);
     OnLogUpdated?.Invoke(logBuilder, EventArgs.Empty);
 }