private void DrawAnimIdSelector(object animator) { if (animator == null) { this.DrawPropertyField(PROP_ID); return; } using (var lst = com.spacepuppy.Collections.TempCollection.GetList <string>()) { GetAnimationIds(lst, animator); if (lst.Count == 0) { this.DrawPropertyField(PROP_ID); return; } else { var propId = this.serializedObject.FindProperty(PROP_ID); propId.stringValue = SPEditorGUILayout.OptionPopupWithCustom(propId.displayName, propId.stringValue, lst.ToArray()); } } }