From the course: Android App Development: Accessibility

Unlock the full course today

Join today to access over 22,500 courses taught by industry experts or purchase this course individually.

Update default focus navigation

Update default focus navigation - Android Tutorial

From the course: Android App Development: Accessibility

Start my 1-month free trial

Update default focus navigation

- [Instructor] Let's explore the focus navigation of our sample web. But, first, make sure to connect a Bluetooth keyboard to your device. If you are using the emulator, you can use your computer keyboard to test it, but just make sure that first you go to Tools, AVD Manager and when you create your device, you go to the Show Advanced Settings and under Keyboard, make sure that Enable keyboard input is checked. Our example app is already navigable using a keyboard. This is because I'm using native components and they already implement support for focused navigation. Note, however, that the focus indicator is not that strong. This is part of the material design styles and this is, in fact, an accessibility problem since the focus indicator should be highly visible. There are two ways to override this. First, you can provide your own custom indicator. To do that, you need to create two drawables. In Android Studio, go to the drawables folder and notice that we already have these two…

Contents