private SetAutoInstrumentedAssemblies ( InstrumentedAssemblyTypes value ) : void | ||
value | InstrumentedAssemblyTypes | |
Résultat | void |
public override void OnGUI(Rect rect) { Rect source = new Rect(rect); if (this.m_ShowAutoInstrumemtationParams) { Rect position = new Rect(source) { height = 20f }; InstrumentedAssemblyTypes none = InstrumentedAssemblyTypes.None; if (GUI.Toggle(position, (this.m_AutoInstrumentedAssemblyTypes & InstrumentedAssemblyTypes.Script) != InstrumentedAssemblyTypes.None, s_AutoInstrumentScriptsContent)) { none |= InstrumentedAssemblyTypes.Script; } if (none != this.m_AutoInstrumentedAssemblyTypes) { this.m_AutoInstrumentedAssemblyTypes = none; ProfilerDriver.SetAutoInstrumentedAssemblies(this.m_AutoInstrumentedAssemblyTypes); SessionState.SetInt("ProfilerAutoInstrumentedAssemblyTypes", (int)this.m_AutoInstrumentedAssemblyTypes); } source.y += 20f; source.height -= 20f; } this.m_FunctionsList.OnGUI(source); }
public override void OnGUI(Rect rect) { Rect r = new Rect(rect); if (m_ShowAutoInstrumemtationParams) { Rect toggleRect = new Rect(r); toggleRect.height = kAutoInstrumentButtonHeight; // TODO: Use reflection and foreach on InstrumentedAssemblyTypes values var newAutoInstrumentedAssemblies = InstrumentedAssemblyTypes.None; if (GUI.Toggle(toggleRect, (m_AutoInstrumentedAssemblyTypes & InstrumentedAssemblyTypes.Script) != 0, s_AutoInstrumentScriptsContent)) { newAutoInstrumentedAssemblies |= InstrumentedAssemblyTypes.Script; } if (newAutoInstrumentedAssemblies != m_AutoInstrumentedAssemblyTypes) { m_AutoInstrumentedAssemblyTypes = newAutoInstrumentedAssemblies; ProfilerDriver.SetAutoInstrumentedAssemblies(m_AutoInstrumentedAssemblyTypes); SessionState.SetInt(kAutoInstrumentSettingKey, (int)m_AutoInstrumentedAssemblyTypes); } r.y += kAutoInstrumentButtonsHeight; r.height -= kAutoInstrumentButtonsHeight; } m_FunctionsList.OnGUI(r); }
public override void OnGUI(Rect rect) { Rect rect1 = new Rect(rect); if (this.m_ShowAutoInstrumemtationParams) { Rect position = new Rect(rect1); position.height = 20f; InstrumentedAssemblyTypes instrumentedAssemblyTypes = InstrumentedAssemblyTypes.None; if (GUI.Toggle(position, (this.m_AutoInstrumentedAssemblyTypes & InstrumentedAssemblyTypes.Script) != InstrumentedAssemblyTypes.None, ProfilerInstrumentationPopup.s_AutoInstrumentScriptsContent)) { instrumentedAssemblyTypes |= InstrumentedAssemblyTypes.Script; } if (instrumentedAssemblyTypes != this.m_AutoInstrumentedAssemblyTypes) { this.m_AutoInstrumentedAssemblyTypes = instrumentedAssemblyTypes; ProfilerDriver.SetAutoInstrumentedAssemblies(this.m_AutoInstrumentedAssemblyTypes); SessionState.SetInt("ProfilerAutoInstrumentedAssemblyTypes", (int)this.m_AutoInstrumentedAssemblyTypes); } rect1.y += 20f; rect1.height -= 20f; } this.m_FunctionsList.OnGUI(rect1); }