belongs to Maven artifact com.android.support:leanback-v17:28.0.0-alpha1
PlaybackControlsRowPresenter
public
class
PlaybackControlsRowPresenter
extends PlaybackRowPresenter
java.lang.Object | ||||
↳ | android.support.v17.leanback.widget.Presenter | |||
↳ | android.support.v17.leanback.widget.RowPresenter | |||
↳ | android.support.v17.leanback.widget.PlaybackRowPresenter | |||
↳ | android.support.v17.leanback.widget.PlaybackControlsRowPresenter |
A PlaybackControlsRowPresenter renders a PlaybackControlsRow
to display a
series of playback control buttons. Typically this row will be the first row in a fragment
such as the PlaybackFragment
.
The detailed description is rendered using a Presenter
passed in
PlaybackControlsRowPresenter(Presenter)
. Typically this will be an instance of
AbstractDetailsDescriptionPresenter
. The application can access the
detailed description ViewHolder from mDescriptionViewHolder
.
Summary
Nested classes | |
---|---|
class |
PlaybackControlsRowPresenter.ViewHolder
A ViewHolder for the PlaybackControlsRow. |
Inherited constants |
---|
From
class
android.support.v17.leanback.widget.RowPresenter
|
Public constructors | |
---|---|
PlaybackControlsRowPresenter(Presenter descriptionPresenter)
Constructor for a PlaybackControlsRowPresenter. |
|
PlaybackControlsRowPresenter()
Constructor for a PlaybackControlsRowPresenter. |
Public methods | |
---|---|
boolean
|
areSecondaryActionsHidden()
Returns true if secondary actions are hidden. |
int
|
getBackgroundColor()
Returns the background color. |
OnActionClickedListener
|
getOnActionClickedListener()
Returns the listener for |
int
|
getProgressColor()
Returns the primary color for the progress bar. |
void
|
onReappear(RowPresenter.ViewHolder rowViewHolder)
Provides hook to update the UI when the view reappears. |
void
|
setBackgroundColor(int color)
Sets the background color. |
void
|
setOnActionClickedListener(OnActionClickedListener listener)
Sets the listener for |
void
|
setProgressColor(int color)
Sets the primary color for the progress bar. |
void
|
setSecondaryActionsHidden(boolean hidden)
Sets the secondary actions to be hidden behind a "more actions" button. |
void
|
showBottomSpace(PlaybackControlsRowPresenter.ViewHolder vh, boolean show)
Shows or hides space at the bottom of the playback controls row. |
void
|
showPrimaryActions(PlaybackControlsRowPresenter.ViewHolder vh)
Displays the primary actions. |
Protected methods | |
---|---|
RowPresenter.ViewHolder
|
createRowViewHolder(ViewGroup parent)
Called to create a ViewHolder object for a Row. |
void
|
onBindRowViewHolder(RowPresenter.ViewHolder holder, Object item)
Binds the given row object to the given ViewHolder. |
void
|
onRowViewAttachedToWindow(RowPresenter.ViewHolder vh)
Invoked when the row view is attached to the window. |
void
|
onRowViewDetachedFromWindow(RowPresenter.ViewHolder vh)
Invoked when the row view is detached from the window. |
void
|
onRowViewSelected(RowPresenter.ViewHolder vh, boolean selected)
Called when the given row view changes selection state. |
void
|
onUnbindRowViewHolder(RowPresenter.ViewHolder holder)
Unbinds the given ViewHolder. |
Inherited methods | |
---|---|
From
class
android.support.v17.leanback.widget.PlaybackRowPresenter
| |
From
class
android.support.v17.leanback.widget.RowPresenter
| |
From
class
android.support.v17.leanback.widget.Presenter
| |
From
class
java.lang.Object
| |
From
interface
android.support.v17.leanback.widget.FacetProvider
|
Public constructors
PlaybackControlsRowPresenter
PlaybackControlsRowPresenter (Presenter descriptionPresenter)
Constructor for a PlaybackControlsRowPresenter.
Parameters | |
---|---|
descriptionPresenter |
Presenter : Presenter for displaying item details.
|
PlaybackControlsRowPresenter
PlaybackControlsRowPresenter ()
Constructor for a PlaybackControlsRowPresenter.
Public methods
areSecondaryActionsHidden
boolean areSecondaryActionsHidden ()
Returns true if secondary actions are hidden.
Returns | |
---|---|
boolean |
getBackgroundColor
int getBackgroundColor ()
Returns the background color. If no background color was set, transparent is returned.
Returns | |
---|---|
int |
getOnActionClickedListener
OnActionClickedListener getOnActionClickedListener ()
Returns the listener for Action
click events.
Returns | |
---|---|
OnActionClickedListener |
getProgressColor
int getProgressColor ()
Returns the primary color for the progress bar. If no color was set, transparent is returned.
Returns | |
---|---|
int |
onReappear
void onReappear (RowPresenter.ViewHolder rowViewHolder)
Provides hook to update the UI when the view reappears.
Parameters | |
---|---|
rowViewHolder |
RowPresenter.ViewHolder |
setBackgroundColor
void setBackgroundColor (int color)
Sets the background color. If not set, a default from the theme will be used.
Parameters | |
---|---|
color |
int |
setOnActionClickedListener
void setOnActionClickedListener (OnActionClickedListener listener)
Sets the listener for Action
click events.
Parameters | |
---|---|
listener |
OnActionClickedListener |
setProgressColor
void setProgressColor (int color)
Sets the primary color for the progress bar. If not set, a default from the theme will be used.
Parameters | |
---|---|
color |
int |
setSecondaryActionsHidden
void setSecondaryActionsHidden (boolean hidden)
Sets the secondary actions to be hidden behind a "more actions" button. When "more actions" is selected, the primary actions are replaced with the secondary actions.
Parameters | |
---|---|
hidden |
boolean |
showBottomSpace
void showBottomSpace (PlaybackControlsRowPresenter.ViewHolder vh, boolean show)
Shows or hides space at the bottom of the playback controls row. This allows the row to hug the bottom of the display when no other rows are present.
Parameters | |
---|---|
vh |
PlaybackControlsRowPresenter.ViewHolder |
show |
boolean |
showPrimaryActions
void showPrimaryActions (PlaybackControlsRowPresenter.ViewHolder vh)
Displays the primary actions. This will override the user having selected "more actions"
to display the secondary actions; see setSecondaryActionsHidden(boolean)
.
Parameters | |
---|---|
vh |
PlaybackControlsRowPresenter.ViewHolder |
Protected methods
createRowViewHolder
RowPresenter.ViewHolder createRowViewHolder (ViewGroup parent)
Called to create a ViewHolder object for a Row. Subclasses will override this method to return a different concrete ViewHolder object.
Parameters | |
---|---|
parent |
ViewGroup : The parent View for the Row's view holder. |
Returns | |
---|---|
RowPresenter.ViewHolder |
A ViewHolder for the Row's View. |
onBindRowViewHolder
void onBindRowViewHolder (RowPresenter.ViewHolder holder, Object item)
Binds the given row object to the given ViewHolder.
Derived classes of RowPresenter
overriding
onBindRowViewHolder(ViewHolder, Object)
must call through the super class's
implementation of this method.
Parameters | |
---|---|
holder |
RowPresenter.ViewHolder |
item |
Object |
onRowViewAttachedToWindow
void onRowViewAttachedToWindow (RowPresenter.ViewHolder vh)
Invoked when the row view is attached to the window.
Parameters | |
---|---|
vh |
RowPresenter.ViewHolder |
onRowViewDetachedFromWindow
void onRowViewDetachedFromWindow (RowPresenter.ViewHolder vh)
Invoked when the row view is detached from the window.
Parameters | |
---|---|
vh |
RowPresenter.ViewHolder |
onRowViewSelected
void onRowViewSelected (RowPresenter.ViewHolder vh, boolean selected)
Called when the given row view changes selection state. A subclass may override this to respond to selected state changes of a Row. A subclass may make visual changes to Row view but must not create animation on the Row view.
Parameters | |
---|---|
vh |
RowPresenter.ViewHolder |
selected |
boolean |
onUnbindRowViewHolder
void onUnbindRowViewHolder (RowPresenter.ViewHolder holder)
Unbinds the given ViewHolder.
Derived classes of RowPresenter
overriding onUnbindRowViewHolder(ViewHolder)
must call through the super class's implementation of this method.
Parameters | |
---|---|
holder |
RowPresenter.ViewHolder |
Interfaces
- BaseGridView.OnKeyInterceptListener
- BaseGridView.OnMotionInterceptListener
- BaseGridView.OnTouchInterceptListener
- BaseGridView.OnUnhandledKeyListener
- BaseOnItemViewClickedListener
- BaseOnItemViewSelectedListener
- BrowseFrameLayout.OnChildFocusListener
- BrowseFrameLayout.OnFocusSearchListener
- FacetProvider
- FacetProviderAdapter
- FocusHighlight
- FragmentAnimationProvider
- ImeKeyMonitor
- ImeKeyMonitor.ImeKeyListener
- MultiActionsProvider
- OnActionClickedListener
- OnChildLaidOutListener
- OnChildSelectedListener
- OnItemViewClickedListener
- OnItemViewSelectedListener
- PlaybackSeekUi
- SearchBar.SearchBarListener
- SearchBar.SearchBarPermissionListener
- SearchEditText.OnKeyboardDismissListener
- SpeechRecognitionCallback
- TitleViewAdapter.Provider
- ViewHolderTask
Classes
- AbstractDetailsDescriptionPresenter
- AbstractDetailsDescriptionPresenter.ViewHolder
- AbstractMediaItemPresenter
- AbstractMediaItemPresenter.ViewHolder
- AbstractMediaListHeaderPresenter
- AbstractMediaListHeaderPresenter.ViewHolder
- Action
- ArrayObjectAdapter
- BaseCardView
- BaseCardView.LayoutParams
- BaseGridView
- BrowseFrameLayout
- ClassPresenterSelector
- ControlButtonPresenterSelector
- CursorObjectAdapter
- DetailsOverviewLogoPresenter
- DetailsOverviewLogoPresenter.ViewHolder
- DetailsOverviewRow
- DetailsOverviewRow.Listener
- DetailsOverviewRowPresenter
- DetailsOverviewRowPresenter.ViewHolder
- DetailsParallax
- DiffCallback
- DividerPresenter
- DividerRow
- FocusHighlightHelper
- FullWidthDetailsOverviewRowPresenter
- FullWidthDetailsOverviewRowPresenter.Listener
- FullWidthDetailsOverviewRowPresenter.ViewHolder
- FullWidthDetailsOverviewRowPresenter.ViewHolder.DetailsOverviewRowListener
- FullWidthDetailsOverviewSharedElementHelper
- GuidanceStylist
- GuidanceStylist.Guidance
- GuidedAction
- GuidedAction.Builder
- GuidedAction.BuilderBase
- GuidedActionDiffCallback
- GuidedActionEditText
- GuidedActionsStylist
- GuidedActionsStylist.ViewHolder
- GuidedDatePickerAction
- GuidedDatePickerAction.Builder
- GuidedDatePickerAction.BuilderBase
- HeaderItem
- HorizontalGridView
- HorizontalHoverCardSwitcher
- ImageCardView
- ItemAlignmentFacet
- ItemAlignmentFacet.ItemAlignmentDef
- ItemBridgeAdapter
- ItemBridgeAdapter.AdapterListener
- ItemBridgeAdapter.ViewHolder
- ItemBridgeAdapter.Wrapper
- ItemBridgeAdapterShadowOverlayWrapper
- ListRow
- ListRowHoverCardView
- ListRowPresenter
- ListRowPresenter.SelectItemViewHolderTask
- ListRowPresenter.ViewHolder
- ListRowView
- MultiActionsProvider.MultiAction
- ObjectAdapter
- ObjectAdapter.DataObserver
- OnChildViewHolderSelectedListener
- PageRow
- Parallax
- Parallax.FloatProperty
- Parallax.IntProperty
- Parallax.PropertyMarkerValue
- ParallaxEffect
- ParallaxTarget
- ParallaxTarget.DirectPropertyTarget
- ParallaxTarget.PropertyValuesHolderTarget
- PlaybackControlsRow
- PlaybackControlsRow.ClosedCaptioningAction
- PlaybackControlsRow.FastForwardAction
- PlaybackControlsRow.HighQualityAction
- PlaybackControlsRow.MoreActions
- PlaybackControlsRow.MultiAction
- PlaybackControlsRow.OnPlaybackProgressCallback
- PlaybackControlsRow.PictureInPictureAction
- PlaybackControlsRow.PlayPauseAction
- PlaybackControlsRow.RepeatAction
- PlaybackControlsRow.RewindAction
- PlaybackControlsRow.ShuffleAction
- PlaybackControlsRow.SkipNextAction
- PlaybackControlsRow.SkipPreviousAction
- PlaybackControlsRow.ThumbsAction
- PlaybackControlsRow.ThumbsDownAction
- PlaybackControlsRow.ThumbsUpAction
- PlaybackControlsRowPresenter
- PlaybackControlsRowPresenter.ViewHolder
- PlaybackRowPresenter
- PlaybackRowPresenter.ViewHolder
- PlaybackSeekDataProvider
- PlaybackSeekDataProvider.ResultCallback
- PlaybackSeekUi.Client
- PlaybackTransportRowPresenter
- PlaybackTransportRowPresenter.ViewHolder
- Presenter
- Presenter.ViewHolder
- Presenter.ViewHolderTask
- PresenterSelector
- PresenterSwitcher
- RecyclerViewParallax
- RecyclerViewParallax.ChildPositionProperty
- Row
- RowHeaderPresenter
- RowHeaderPresenter.ViewHolder
- RowHeaderView
- RowPresenter
- RowPresenter.ViewHolder
- SearchBar
- SearchEditText
- SearchOrbView
- SearchOrbView.Colors
- SectionRow
- ShadowOverlayContainer
- ShadowOverlayHelper
- ShadowOverlayHelper.Builder
- ShadowOverlayHelper.Options
- SinglePresenterSelector
- SparseArrayObjectAdapter
- SpeechOrbView
- TitleHelper
- TitleView
- TitleViewAdapter
- VerticalGridPresenter
- VerticalGridPresenter.ViewHolder
- VerticalGridView
Content and code samples on this page are subject to the licenses described in the Content License. Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
Last updated 2024-04-11 UTC.