# SetActiveContext

> Sets the active EditorToolContext.

## Definition

* **Type:** Method
* **Namespace:** [UnityEditor.EditorTools](/engine/6000.5/script-reference/unityeditor/editortools.md)
* **Assembly:** UnityEditor.CoreModule

## SetActiveContext(Type)

Sets the active [EditorToolContext](/engine/6000.5/script-reference/unityeditor/editortools/editortoolcontext.md).

```csharp
public static void SetActiveContext(Type context)
```

### Parameters

**** (\[Type]\(https\://learn.microsoft.com/dotnet/api/system.type)): The [EditorToolContext](/engine/6000.5/script-reference/unityeditor/editortools/editortoolcontext.md) type to be set as the active tool.

### Remarks

To restore the manipulation tools to their default behavior, pass [GameObjectToolContext](/engine/6000.5/script-reference/unityeditor/editortools/gameobjecttoolcontext.md) or null to the context argument.

## SetActiveContext\<T>()

Sets the active [EditorToolContext](/engine/6000.5/script-reference/unityeditor/editortools/editortoolcontext.md).

```csharp
public static void SetActiveContext<T>() where T : EditorToolContext
```

### Remarks

To restore the manipulation tools to their default behavior, pass [GameObjectToolContext](/engine/6000.5/script-reference/unityeditor/editortools/gameobjecttoolcontext.md) or null to the context argument.
