UE5 Dev log #6

Regular Navigation Attempt does the job until widgets are placed regularly and evenly. But what if you work with Diablo like inventory where each item is considered a button and can be placed all over the container? Regular up/down may not find any widget as it does "UI line trace".

I tried approach with setting Custom Navigation Rule on the container, which allows to call a method. Virtually ideally but it appeared that this method has higher priority than the regular navigation inside the container. This means Custom method bound to Up Navigation will be called always, even if we'd rather focus on button inside the same container.

Solution that finally worked for me was caching previous focused widget and checking it in OnFocusReceived of the container. Now I can compute the distance for each button in new container and focus on the closest one.

Read more