Most visited

Recently visited

BaseLeanbackPreferenceFragment

public abstract class BaseLeanbackPreferenceFragment
extends PreferenceFragment

java.lang.Object
   ↳ android.app.Fragment
     ↳ android.support.v14.preference.PreferenceFragment
       ↳ android.support.v17.preference.BaseLeanbackPreferenceFragment
Known Direct Subclasses


此片段提供了具有背式样行为的首选片段,适合嵌入到更广泛的UI元素中。

Summary

Inherited XML attributes

From class android.support.v14.preference.PreferenceFragment
From class android.app.Fragment

Inherited constants

From class android.support.v14.preference.PreferenceFragment
From interface android.content.ComponentCallbacks2

Public constructors

BaseLeanbackPreferenceFragment()

Public methods

RecyclerView onCreateRecyclerView(LayoutInflater inflater, ViewGroup parent, Bundle savedInstanceState)

创建用于显示首选项的 RecyclerView

Inherited methods

From class android.support.v14.preference.PreferenceFragment
From class android.app.Fragment
From class java.lang.Object
From interface android.support.v7.preference.PreferenceManager.OnPreferenceTreeClickListener
From interface android.support.v7.preference.PreferenceManager.OnDisplayPreferenceDialogListener
From interface android.support.v7.preference.PreferenceManager.OnNavigateToScreenListener
From interface android.support.v7.preference.DialogPreference.TargetFragment
From interface android.content.ComponentCallbacks2
From interface android.view.View.OnCreateContextMenuListener
From interface android.content.ComponentCallbacks

Public constructors

BaseLeanbackPreferenceFragment

BaseLeanbackPreferenceFragment ()

Public methods

onCreateRecyclerView

RecyclerView onCreateRecyclerView (LayoutInflater inflater, 
                ViewGroup parent, 
                Bundle savedInstanceState)

创建用于显示首选项的RecyclerView 子类可以覆盖此以返回自定义的RecyclerView

Parameters
inflater LayoutInflater: The LayoutInflater object that can be used to inflate the RecyclerView.
parent ViewGroup: The parent View that the RecyclerView will be attached to. This method should not add the view itself, but this can be used to generate the LayoutParams of the view.
savedInstanceState Bundle: If non-null, this view is being re-constructed from a previous saved state as given here
Returns
RecyclerView A new RecyclerView object to be placed into the view hierarchy

Hooray!