Move focus inside frame

We currently have a DrawerLayout containing FrameLayout and LinearLayout with footer information. FrameLayout contains fragments of content. In accessibility mode, the footer focuses in front of the frame. We want the contents of the frame to focus first on the focus. However, a LinearLayout containing footer information always gets focus before the contents of the FrameLayout.

We tried to add <requestFocus />both to FrameLayout and to the contents of FrameLayout with and without :focusableand :focusableInTouchMode, to set the value to true, <setFocusForward>in FrameLayout and call requestFocus()a fragment in the content. requestFocus()returns true, but does not maintain focus.

layout.xml

<android.support.v4.widget.DrawerLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:tools="http://schemas.android.com/tools"
    android:id="@+id/drawer_layout"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    tools:context=".NavigationControllerActivity" >

<LinearLayout
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:baselineAligned="false"
    android:orientation="vertical" >

    <FrameLayout
        android:id="@+id/container"
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:layout_weight="1"
        android:background="#FFFFFF" >
    </FrameLayout>

    <LinearLayout
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:layout_weight="8"
        android:orientation="vertical" >

        <TextView/>

    </LinearLayout>

- FrameLayout LinearLayout ?

+4
1

set

android:importantForAccessibility = "true"

Framelayout

-2

All Articles