Home | History | Annotate | Download | only in layout
      1 <!--
      2   ~ Copyright (C) 2015 The Android Open Source Project
      3   ~
      4   ~ Licensed under the Apache License, Version 2.0 (the "License");
      5   ~ you may not use this file except in compliance with the License.
      6   ~ You may obtain a copy of the License at
      7   ~
      8   ~      http://www.apache.org/licenses/LICENSE-2.0
      9   ~
     10   ~ Unless required by applicable law or agreed to in writing, software
     11   ~ distributed under the License is distributed on an "AS IS" BASIS,
     12   ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     13   ~ See the License for the specific language governing permissions and
     14   ~ limitations under the License.
     15   -->
     16 
     17 <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
     18               xmlns:app="http://schemas.android.com/apk/res-auto"
     19               android:orientation="vertical"
     20               android:layout_width="fill_parent"
     21               android:layout_height="fill_parent">
     22 
     23     <android.support.v7.widget.RecyclerView
     24             android:id="@+id/clipToPaddingNo"
     25             android:layout_width="fill_parent"
     26             app:layoutManager="LinearLayoutManager"
     27             android:clipToPadding="false"
     28             android:layout_height="100dp"/>
     29 
     30     <android.support.v7.widget.RecyclerView
     31             android:id="@+id/clipToPaddingUndefined"
     32             android:layout_width="fill_parent"
     33             app:layoutManager="LinearLayoutManager"
     34             android:layout_height="100dp"/>
     35 
     36     <android.support.v7.widget.RecyclerView
     37             android:id="@+id/clipToPaddingYes"
     38             android:layout_width="fill_parent"
     39             app:layoutManager="LinearLayoutManager"
     40             android:clipToPadding="true"
     41             android:layout_height="100dp"/>
     42 
     43     <android.support.v7.widget.RecyclerView
     44             android:id="@+id/recyclerView"
     45             android:layout_width="fill_parent"
     46             android:layout_height="100dp"
     47             app:layoutManager="GridLayoutManager"
     48             android:orientation="horizontal"
     49             app:spanCount="3"
     50             app:reverseLayout="true"/>
     51 
     52     <android.support.v7.widget.RecyclerView
     53             android:id="@+id/recyclerView2"
     54             android:layout_width="fill_parent"
     55             android:layout_height="100dp"
     56             app:layoutManager=".CustomLayoutManager"
     57             android:orientation="vertical"
     58             app:stackFromEnd="true"/>
     59 
     60     <android.support.v7.widget.RecyclerView
     61             android:id="@+id/recyclerView3"
     62             android:layout_width="fill_parent"
     63             android:layout_height="100dp"
     64             app:layoutManager=".CustomLayoutManager$LayoutManager"/>
     65 
     66     <android.support.v7.widget.RecyclerView
     67             android:id="@+id/recyclerView4"
     68             android:layout_width="fill_parent"
     69             android:layout_height="100dp"
     70             app:layoutManager=".PrivateLayoutManager"/>
     71 
     72     <android.support.v7.widget.RecyclerView
     73             android:id="@+id/recyclerView5"
     74             android:layout_width="fill_parent"
     75             android:layout_height="100dp"/>
     76 
     77     <android.support.v7.widget.RecyclerView
     78             android:id="@+id/recyclerView6"
     79             android:layout_width="fill_parent"
     80             android:layout_height="100dp"
     81             android:nestedScrollingEnabled="false"/>
     82 
     83     <android.support.v7.widget.RecyclerView
     84             android:id="@+id/focusability_undefined"
     85             android:layout_width="fill_parent"
     86             android:layout_height="100dp"/>
     87 
     88     <android.support.v7.widget.RecyclerView
     89             android:id="@+id/focusability_after"
     90             android:layout_width="fill_parent"
     91             android:layout_height="100dp"
     92             android:descendantFocusability="afterDescendants"/>
     93 
     94     <android.support.v7.widget.RecyclerView
     95             android:id="@+id/focusability_before"
     96             android:layout_width="fill_parent"
     97             android:layout_height="100dp"
     98             android:descendantFocusability="beforeDescendants"/>
     99 
    100     <android.support.v7.widget.RecyclerView
    101             android:id="@+id/focusability_block"
    102             android:layout_width="fill_parent"
    103             android:layout_height="100dp"
    104             android:descendantFocusability="blocksDescendants"/>
    105 
    106 </LinearLayout>