private void EditClicked() { var window = ListViewWindow.Show(_serializedTargetObject, _propertyPath, _windowName); window.OnChanged += AnyFieldChanged; window.OnClosed += EditClosed; _window = window; }
public static void CloseIfAny() { while (!HasOpenInstances <ListViewWindow>()) { GetWindow <ListViewWindow>().Close(); } s_currentInstance = null; }
public static ListViewWindow Show(Object targetObject, string propertyPath, string displayName) { var window = new ListViewWindow(); window._serializedTargetObject = targetObject; window._propertyPath = propertyPath; window.titleContent = new GUIContent(displayName); window.ShowUtility(); window.Focus(); return(window); }
private void OnDisable() { s_currentInstance = null; if (!_disposed) { _sObject.Dispose(); _property.Dispose(); } OnClosed?.Invoke(); }
private void OnEnable() { CloseIfAny(); s_currentInstance = this; }
private void EditClosed() { Unsubscribe(); _window = null; }