# OnViewDetached()

> Called when the condition's row is detached from its UI panel.

## Definition

* **Type:** Method
* **Namespace:** [Unity.GraphToolkit.Editor](/engine/6000.7/script-reference/unity/graphtoolkit/editor.md)
* **Assembly:** UnityEditor

```csharp
public virtual void OnViewDetached()
```

### Remarks

Like [ConditionView\<T>.OnViewAttached](/engine/6000.7/script-reference/unity/graphtoolkit/editor/conditionview1/onviewattached.md), this can fire multiple times during the view's lifetime, and a matching [ConditionView\<T>.OnViewAttached](/engine/6000.7/script-reference/unity/graphtoolkit/editor/conditionview1/onviewattached.md) may follow. Use this callback to release resources tied to panel presence, such as event subscriptions.
