Beispiel #1
0
            public void Init(ProfilerFrameDataMultiColumnHeader.Column[] columns, IProfilerSampleNameProvider profilerSampleNameProvider)
            {
                if (m_Initialized)
                {
                    return;
                }

                m_StringProperties = new string[columns.Length];
                for (var i = 0; i < columns.Length; i++)
                {
                    var    profilerColumn = columns[i].profilerColumn;
                    string data;
                    if (columns[i].profilerColumn == HierarchyFrameDataView.columnName)
                    {
                        data        = profilerSampleNameProvider.GetItemName(m_FrameDataView, id);
                        displayName = data;
                    }
                    else
                    {
                        data = m_FrameDataView.GetItemColumnData(id, columns[i].profilerColumn);
                    }
                    m_StringProperties[i] = data;
                }

                m_Initialized = true;
            }
Beispiel #2
0
 public ProfilerFrameDataTreeView(TreeViewState state, ProfilerFrameDataMultiColumnHeader multicolumnHeader, IProfilerSampleNameProvider profilerSampleNameProvider)
     : base(state, multicolumnHeader)
 {
     Assert.IsNotNull(multicolumnHeader);
     deselectOnUnhandledMouseDown        = true;
     m_ProfilerSampleNameProvider        = profilerSampleNameProvider;
     m_MultiColumnHeader                 = multicolumnHeader;
     m_MultiColumnHeader.sortingChanged += OnSortingChanged;
 }
 override public void OnEnable(CPUorGPUProfilerModule cpuModule)
 {
     profilerSampleNameProvider = cpuModule;
 }