# GetFocusChangeDirection(Focusable, EventBase)

> Get the direction of the focus change for the given event.

## Definition

* **Type:** Method
* **Namespace:** [UnityEngine.UIElements](/engine/6000.6/script-reference/unityengine/uielements.md)
* **Assembly:** UnityEngine.UIElementsModule

```csharp
FocusChangeDirection GetFocusChangeDirection(Focusable currentFocusable, EventBase e)
```

### Parameters

**** (\[Focusable]\(/engine/6000.6/script-reference/unityengine/uielements/focusable)): **** (\[EventBase]\(/engine/6000.6/script-reference/unityengine/uielements/eventbase)):&#x20;

### Returns

| Type                                                                                                   | Description |
| ------------------------------------------------------------------------------------------------------ | ----------- |
| [FocusChangeDirection](/engine/6000.6/script-reference/unityengine/uielements/focuschangedirection.md) |             |

### Remarks

For example, in a [VisualElementFocusRing](/engine/6000.6/script-reference/unityengine/uielements/visualelementfocusring.md), when the Tab key is pressed, the focus change direction should be [\_right](/engine/6000.6/script-reference/unityengine/uielements/visualelementfocuschangedirection/right.md).

When the [EventDispatcher](/engine/6000.6/script-reference/unityengine/uielements/eventdispatcher.md) processes navigation and pointer events, it automatically calls this method to generate Focus events.

The Focus event's [\_direction](/engine/6000.6/script-reference/unityengine/uielements/ifocusevent/direction.md) matches the value returned by this method to generate it.
