Example #1
0
        private void EventReceived(TraceEvent traceEvent)
        {
            DisplayTraceEvent dte = new DisplayTraceEvent
            {
                TraceEvent = traceEvent,
            };

            foreach (IDisplayTraceEvents idt in _viewers)
            {
                if (idt.IsApplicable(traceEvent))
                {
                    dte.DisplayTemplates.Add(idt.GetDisplayTemplate());

                    DataTemplate listTemplate = idt.GetListItemTemplate();

                    if (listTemplate != null)
                    {
                        dte.ListTemplate = listTemplate;
                    }
                }
            }

            DisplayTraceEvents.Add(dte);
            SelectedTab = 0;
        }
Example #2
0
        private void EventReceived(TraceEvent traceEvent)
        {
            DisplayTraceEvent dte = new DisplayTraceEvent
            {
                TraceEvent = traceEvent,
            };

            foreach (IDisplayTraceEvents idt in _viewers)
            {
                if (idt.IsApplicable(traceEvent))
                {
                    dte.DisplayTemplates.Add(idt.GetDisplayTemplate());

                    DataTemplate listTemplate = idt.GetListItemTemplate();

                    if (listTemplate != null)
                    {
                        dte.ListTemplate = listTemplate;
                    }
                }
            }

            DisplayTraceEvents.Add(dte);
            SelectedTab = 0;
        }