UniTvFragment

class UniTvFragment : Fragment, CustomUniTVFragmentInterface

Constructors

Link copied to clipboard
constructor()

Functions

Link copied to clipboard
open override fun clearRecommendView()

Clear recommendation view

Link copied to clipboard
open override fun enterSeekMode(): Boolean

Control state is going to StateType.SEEK_MODE when current control state is one of the below list

Link copied to clipboard
open override fun handleSeekBarOnLeftKeyDown(velocity: Int): Boolean

Handle seek left in seek mode

Link copied to clipboard
open override fun handleSeekBarOnRightKeyDown(velocity: Int): Boolean

Handle seek right in seek mode

Link copied to clipboard
open override fun onActivityCreated(savedInstanceState: Bundle?)
Link copied to clipboard
open override fun onCreate(savedInstanceState: Bundle?)
Link copied to clipboard
open override fun onCreateView(inflater: LayoutInflater, container: ViewGroup?, savedInstanceState: Bundle?): View
Link copied to clipboard
open override fun onDestroy()
Link copied to clipboard
open override fun onKeyDown(keyCode: Int, event: KeyEvent?, keyEventBundle: KeyEventBundle?): Boolean

Activity pass key event to paas, it can be override by custom fragment

Link copied to clipboard
open override fun onKeyUp(keyCode: Int, event: KeyEvent?, keyEventBundle: KeyEventBundle?): Boolean

CustomUniTVFragmentInterface

Link copied to clipboard
open override fun onStart()
Link copied to clipboard
open override fun onStop()
Link copied to clipboard
open override fun onViewCreated(view: View, savedInstanceState: Bundle?)
Link copied to clipboard
open override fun setControlStateEventListener(controlStateEventListener: ControlStateEventListener)

Register a callback to be invoked when control state is changed.

Link copied to clipboard
open override fun setCustomViewId(resId: Int)

Inflate custom layout for project level, this view will append on control panel

Link copied to clipboard
open override fun setPlayerThemeColorStyle(styleId: Int)

To set the ThemeColor

Link copied to clipboard
open override fun setRecommendationListener(recommendationEventListener: RecommendationEventListener)

Register a callback to be invoked when state of recommendation panel is changed.

Link copied to clipboard
open override fun setRecommendViewId(resId: Int)

Inflate recommendation view

Link copied to clipboard
fun setup(uniPlayer: UniPlayer, disableControlPanel: Boolean = false)

setup

Link copied to clipboard
open override fun setupActionButtons(actions: List<ActionButton>)

Setup the customized action buttons below the seekbar. This function should be called after UniTvFragment.setup