VerticalGridFragment
public class VerticalGridFragment extends BaseFragment
| java.lang.Object | ||||
| ↳ | android.app.Fragment | |||
| ↳ | androidx.leanback.app.BrandedFragment | |||
| ↳ | androidx.leanback.app.BaseFragment | |||
| ↳ | androidx.leanback.app.VerticalGridFragment |
A fragment for creating leanback vertical grids.
Renders a vertical grid of objects given a VerticalGridPresenter and an ObjectAdapter.
Summary
Public constructors |
|---|
Public methods |
|
|---|---|
@Nullable ObjectAdapter |
Returns the object adapter. |
@Nullable VerticalGridPresenter |
Returns the grid presenter. |
@Nullable OnItemViewClickedListener |
Returns the item clicked listener. |
@Nullable View |
This method is deprecated. |
void |
This method is deprecated. |
void |
This method is deprecated. |
void |
Sets the object adapter for the fragment. |
void |
Sets the grid presenter. |
void |
Sets an item clicked listener. |
void |
Sets an item selection listener. |
void |
Sets the selected item position. |
Protected methods |
|
|---|---|
@NonNull Object |
Create entrance transition. |
void |
Run entrance transition. |
Inherited Constants |
||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
Inherited methods |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Public constructors
Public methods
public @Nullable OnItemViewClickedListenergetOnItemViewClickedListener()
Returns the item clicked listener.
public @Nullable ViewonCreateView(
LayoutInflater inflater,
@Nullable ViewGroup container,
Bundle savedInstanceState
)
public voidsetOnItemViewClickedListener(
@Nullable OnItemViewClickedListener listener
)
Sets an item clicked listener.
public voidsetOnItemViewSelectedListener(
@Nullable OnItemViewSelectedListener listener
)
Sets an item selection listener.
Protected methods
createEntranceTransition
protected @NonNull ObjectcreateEntranceTransition()
Create entrance transition. Subclass can override to load transition from resource or construct manually. Typically app does not need to override the default transition that browse and details provides.
runEntranceTransition
protected voidrunEntranceTransition(@Nullable Object entranceTransition)
Run entrance transition. Subclass may use TransitionManager to perform go(Scene) or beginDelayedTransition(). App should not override the default implementation of browse and details fragment.