void DeleteRecorder(RecorderItem item) { var s = item.settings; m_ControllerSettings.RemoveRecorder(s); UnityHelpers.Destroy(item.editor, true); m_RecordingListItem.Remove(item); }
void DeleteRecorder(RecorderItem item, bool prompt) { if (!prompt || EditorUtility.DisplayDialog("Delete Recoder?", "Are you sure you want to delete '" + item.settings.name + "' ?", "Delete", "Cancel")) { var s = item.settings; m_ControllerSettings.RemoveRecorder(s); UnityHelpers.Destroy(s, true); UnityHelpers.Destroy(item.editor, true); m_RecordingListItem.Remove(item); } if (prompt) { Focus(); } }