private void DrawCurrentEvent(Rect rect, FrameDebuggerEvent[] descs)
{
int index = FrameDebuggerUtility.limit - 1;
if ((index >= 0) && (index < descs.Length))
{
GUILayout.BeginArea(rect);
FrameDebuggerEvent cur = descs[index];
this.DrawRenderTargetControls(cur);
GUILayout.Label(string.Format("Event #{0}: {1}", index + 1, s_FrameEventTypeNames[(int) cur.type]), EditorStyles.boldLabel, new GUILayoutOption[0]);
if ((cur.vertexCount > 0) || (cur.indexCount > 0))
{
int frameEventShaderID = FrameDebuggerUtility.GetFrameEventShaderID(index);
if (frameEventShaderID != 0)
{
Shader shader = EditorUtility.InstanceIDToObject(frameEventShaderID) as Shader;
if (shader != null)
{
int frameEventShaderPassIndex = FrameDebuggerUtility.GetFrameEventShaderPassIndex(index);
GUILayout.BeginHorizontal(new GUILayoutOption[0]);
object[] objArray1 = new object[] { "Shader: ", shader.name, " pass #", frameEventShaderPassIndex };
GUILayoutOption[] options = new GUILayoutOption[] { GUILayout.ExpandWidth(false) };
if (GUILayout.Button(string.Concat(objArray1), GUI.skin.label, options))
{
EditorGUIUtility.PingObject(shader);
Event.current.Use();
}
GUILayout.Label(FrameDebuggerUtility.GetFrameEventShaderKeywords(index), EditorStyles.miniLabel, new GUILayoutOption[0]);
GUILayout.EndHorizontal();
this.DrawStates();
}
}
if (!this.DrawEventMesh(index, cur))
{
GUILayout.Label("Vertices: " + cur.vertexCount, new GUILayoutOption[0]);
GUILayout.Label("Indices: " + cur.indexCount, new GUILayoutOption[0]);
}
}
GUILayout.EndArea();
}
}