private void MultiParticleSystemGUI(bool verticalLayout)
{
ParticleSystem root = ParticleSystemEditorUtils.GetRoot(this.m_SelectedParticleSystem);
GUILayout.BeginVertical(ParticleSystemStyles.Get().effectBgStyle, new GUILayoutOption[0]);
this.m_EmitterAreaScrollPos = EditorGUILayout.BeginScrollView(this.m_EmitterAreaScrollPos, new GUILayoutOption[0]);
Rect position = EditorGUILayout.BeginVertical(new GUILayoutOption[0]);
this.m_EmitterAreaScrollPos -= EditorGUI.MouseDeltaReader(position, Event.current.alt);
GUILayout.Space(3f);
GUILayout.BeginHorizontal(new GUILayoutOption[0]);
GUILayout.Space(3f);
Color color = GUI.color;
bool flag = Event.current.type == EventType.Repaint;
bool flag2 = this.IsShowOnlySelectedMode();
List<ParticleSystemUI> selectedParticleSystemUIs = this.GetSelectedParticleSystemUIs();
for (int i = 0; i < this.m_Emitters.Length; i++)
{
if (i != 0)
{
GUILayout.Space(ModuleUI.k_SpaceBetweenModules);
}
bool flag3 = selectedParticleSystemUIs.Contains(this.m_Emitters[i]);
ModuleUI particleSystemRendererModuleUI = this.m_Emitters[i].GetParticleSystemRendererModuleUI();
if ((flag && (particleSystemRendererModuleUI != null)) && !particleSystemRendererModuleUI.enabled)
{
GUI.color = GetDisabledColor();
}
if ((flag && flag2) && !flag3)
{
GUI.color = GetDisabledColor();
}
Rect rect = EditorGUILayout.BeginVertical(new GUILayoutOption[0]);
if ((flag && flag3) && (this.m_Emitters.Length > 1))
{
this.DrawSelectionMarker(rect);
}
this.m_Emitters[i].OnGUI(root, ModuleUI.k_CompactFixedModuleWidth, true);
EditorGUILayout.EndVertical();
GUI.color = color;
}
GUILayout.Space(5f);
GUILayoutOption[] options = new GUILayoutOption[] { GUILayout.Width(20f) };
if (GUILayout.Button(s_Texts.addParticleSystem, "OL Plus", options))
{
this.CreateParticleSystem(root, SubModuleUI.SubEmitterType.None);
}
GUILayout.FlexibleSpace();
GUILayout.EndHorizontal();
GUILayout.Space(4f);
this.m_EmitterAreaScrollPos -= EditorGUI.MouseDeltaReader(position, true);
GUILayout.FlexibleSpace();
EditorGUILayout.EndVertical();
EditorGUILayout.EndScrollView();
GUILayout.EndVertical();
this.HandleKeyboardShortcuts(root);
}