FullWidthDetailsOverviewRowPresenter

public class FullWidthDetailsOverviewRowPresenter
extends RowPresenter

java.lang.Object
   ↳ androidx.leanback.widget.Presenter
     ↳ androidx.leanback.widget.RowPresenter
       ↳ androidx.leanback.widget.FullWidthDetailsOverviewRowPresenter


Renders a DetailsOverviewRow to display an overview of an item. Typically this row will be the first row in a fragment such as the DetailsFragment. The View created by the FullWidthDetailsOverviewRowPresenter is made in three parts: logo view on the left, action list view on the top and a customizable detailed description view on the right.

The detailed description is rendered using a Presenter passed in FullWidthDetailsOverviewRowPresenter(Presenter). Typically this will be an instance of AbstractDetailsDescriptionPresenter. The application can access the detailed description ViewHolder from FullWidthDetailsOverviewRowPresenter.ViewHolder.getDetailsDescriptionViewHolder().

The logo view is rendered using a customizable DetailsOverviewLogoPresenter passed in FullWidthDetailsOverviewRowPresenter(Presenter, DetailsOverviewLogoPresenter). The application can access the logo ViewHolder from FullWidthDetailsOverviewRowPresenter.ViewHolder.getLogoViewHolder().

To support activity shared element transition, call setListener(Listener) with FullWidthDetailsOverviewSharedElementHelper during Activity's onCreate(). Application is free to create its own "shared element helper" class using the Listener for image binding. Call setParticipatingEntranceTransition(boolean) with false

The view has three states: STATE_HALF STATE_FULL and STATE_SMALL. See DetailsFragment where it switches states based on selected row position.

Summary

Nested classes

class FullWidthDetailsOverviewRowPresenter.Listener

Listeners for events on ViewHolder. 

class FullWidthDetailsOverviewRowPresenter.ViewHolder

A ViewHolder for the DetailsOverviewRow. 

Constants

int ALIGN_MODE_MIDDLE

This is the alignment mode that the ending edge of logo and the starting edge of description align to the middle of the overview view.

int ALIGN_MODE_START

This is the alignment mode that the logo and description align to the starting edge of the overview view.

int STATE_FULL

This is the state when the view covers full width and height of screen.

int STATE_HALF

This is the default state corresponding to layout file.

int STATE_SMALL

This is the state where the view shrinks to a small banner.

Inherited constants

Fields

protected int mInitialState

Public constructors

FullWidthDetailsOverviewRowPresenter(Presenter detailsPresenter)

Constructor for a FullWidthDetailsOverviewRowPresenter.

FullWidthDetailsOverviewRowPresenter(Presenter detailsPresenter, DetailsOverviewLogoPresenter logoPresenter)

Constructor for a FullWidthDetailsOverviewRowPresenter.

Public methods

final int getActionsBackgroundColor()

Returns the background color of actions.

final int getAlignmentMode()

Returns alignment mode of Description.

final int getBackgroundColor()

Returns the background color.

final int getInitialState()

Returns the initial state used to create ViewHolder.

OnActionClickedListener getOnActionClickedListener()

Returns the listener for Action click events.

final boolean isParticipatingEntranceTransition()

Returns true if the overview should be part of shared element transition.

final boolean isUsingDefaultSelectEffect()

Returns true if this RowPresenter is using the default dimming effect.

final void notifyOnBindLogo(FullWidthDetailsOverviewRowPresenter.ViewHolder viewHolder)

Called by DetailsOverviewLogoPresenter to notify logo was bound to view.

final void setActionsBackgroundColor(int color)

Sets the background color for Action Bar.

final void setAlignmentMode(int alignmentMode)

Set alignment mode of Description.

final void