Пример #1
0
 private void Initialize()
 {
     ExpandablePart.ExpandablePartStateChanged callback = RestructLayout;
     mainPanel.Controls.Add(dummyHead);
     basicInfoPart          = new TraceDetailBasicInfoPart(callback);
     basicInfoPart.TabIndex = 1;
     mainPanel.Controls.Add(basicInfoPart);
     appDataPart          = new TraceDetailAppDataPart(callback);
     appDataPart.TabIndex = 2;
     mainPanel.Controls.Add(appDataPart);
     listPart          = new TraceDetailListPart(callback);
     listPart.TabIndex = 6;
     mainPanel.Controls.Add(listPart);
     exceptionPart          = new TraceDetailExceptionPart(callback);
     exceptionPart.TabIndex = 3;
     mainPanel.Controls.Add(exceptionPart);
     diagPart          = new TraceDetailDiagnosticsPart(callback);
     diagPart.TabIndex = 7;
     mainPanel.Controls.Add(diagPart);
     messageInfoPart          = new TraceDetailMessageInfoPart(callback);
     messageInfoPart.TabIndex = 4;
     mainPanel.Controls.Add(messageInfoPart);
     messageLogInfoPart          = new TraceDetailMessageLogInfoPart(callback);
     messageLogInfoPart.TabIndex = 5;
     mainPanel.Controls.Add(messageLogInfoPart);
     mainPanel.Controls.Add(dummyFoot);
     HideAllParts();
 }
Пример #2
0
 void IAdvancedTraceInfoProvider.ReloadTrace(TraceRecord trace, TraceDetailInfoControlParam param)
 {
     if (trace != null)
     {
         SuspendLayout();
         try
         {
             activeParts.Clear();
             HideAllParts();
             TraceDetailedProcessParameter traceDetailedProcessParameter = new TraceDetailedProcessParameter(trace);
             if (param != null && param.ShowBasicInfo)
             {
                 basicInfoPart.Visible = true;
                 basicInfoPart.ReloadTracePart(traceDetailedProcessParameter);
                 activeParts.AddLast(basicInfoPart);
             }
             if (TraceDetailAppDataPart.ContainsMatchProperties(traceDetailedProcessParameter))
             {
                 appDataPart.Visible = true;
                 appDataPart.ReloadTracePart(traceDetailedProcessParameter);
                 activeParts.AddLast(appDataPart);
             }
             if (TraceDetailExceptionPart.ContainsMatchProperties(traceDetailedProcessParameter))
             {
                 exceptionPart.Visible = true;
                 exceptionPart.ReloadTracePart(traceDetailedProcessParameter);
                 activeParts.AddLast(exceptionPart);
             }
             if (TraceDetailMessageInfoPart.ContainsMatchProperties(traceDetailedProcessParameter))
             {
                 messageInfoPart.Visible = true;
                 messageInfoPart.ReloadTracePart(traceDetailedProcessParameter);
                 activeParts.AddLast(messageInfoPart);
             }
             if (TraceDetailMessageLogInfoPart.ContainsMatchProperties(traceDetailedProcessParameter))
             {
                 messageLogInfoPart.Visible = true;
                 messageLogInfoPart.ReloadTracePart(traceDetailedProcessParameter);
                 activeParts.AddLast(messageLogInfoPart);
             }
             if (traceDetailedProcessParameter.PropertyCount != 0)
             {
                 listPart.Visible = true;
                 listPart.ReloadTracePart(traceDetailedProcessParameter);
                 activeParts.AddLast(listPart);
             }
             if (param != null && param.ShowDiagnosticsInfo && TraceDetailDiagnosticsPart.ContainsMatchProperties(traceDetailedProcessParameter))
             {
                 diagPart.Visible = true;
                 diagPart.ReloadTracePart(traceDetailedProcessParameter);
                 activeParts.AddLast(diagPart);
             }
             RestructLayout(null);
         }
         finally
         {
             ResumeLayout();
         }
     }
 }