com.ooyala.android.ui.OptimizedOoyalaPlayerLayoutController Class Reference

This LayoutController is a faster LayoutController that will work only on one specific case: The OoyalaPlayerLayout it controls is a direct child of the Activity's base layout which is a FrameLayout. More...

Inheritance diagram for com.ooyala.android.ui.OptimizedOoyalaPlayerLayoutController:
com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController com.ooyala.android.ui.LayoutController

Public Member Functions

 OptimizedOoyalaPlayerLayoutController (OoyalaPlayerLayout l, OoyalaPlayer p)
 Instantiate a FastOoyalaPlayerLayoutController. More...
 
 OptimizedOoyalaPlayerLayoutController (OoyalaPlayerLayout l, OoyalaPlayer p, DefaultControlStyle dcs)
 Instantiate a FastOoyalaPlayerLayoutController. More...
 
boolean isFullscreen ()
 
void addVideoView (View videoView)
 Insert the video view into the view hierarchy. More...
 
void removeVideoView ()
 Remove any previously added video view, and related items such as the TV Ratings view. More...
 
void reshowTVRating ()
 Reshow TV rating (if the current FCCTVRatingConfiguration allows it). More...
 
void setInlineOverlay (OoyalaPlayerControls controlsOverlay)
 
void setFullscreenOverlay (OoyalaPlayerControls controlsOverlay)
 
void setInlineControls (OoyalaPlayerControls controls)
 
void setFullscreenControls (OoyalaPlayerControls controls)
 
OoyalaPlayer getPlayer ()
 Get the OoyalaPlayer associated with this Controller. More...
 
FrameLayout getLayout ()
 Get the current active layout. More...
 
OoyalaPlayerControls getControls ()
 
OoyalaPlayerControls getOverlay ()
 
boolean onTouchEvent (MotionEvent event, OoyalaPlayerLayout source)
 Handle the touch events from OoyalaPlayerLayout. More...
 
boolean onKeyUp (int keyCode, KeyEvent event)
 Handle the keydown events from OoyalaPlayerLayout. More...
 
final void setFullscreen (boolean fullscreen)
 Set the fullscreen state. More...
 
OoyalaPlayerControls createDefaultControls (OoyalaPlayerLayout layout, boolean fullscreen)
 
void showClosedCaptionsMenu ()
 Create and display the list of available languages. More...
 
void setFullscreenButtonShowing (boolean showing)
 setFullscreenButtonShowing will enable and disable visibility of the fullscreen button More...
 
void setClosedCaptionsPresentationStyle ()
 
ClosedCaptionsStyle getClosedCaptionsStyle ()
 
void setClosedCaptionsStyle (ClosedCaptionsStyle closedCaptionsStyle)
 Set the ClosedCaptionsStyle. More...
 
void setClosedCaptionsBottomMargin (int bottomMargin)
 Set the bottomMargin of closedCaptions view. More...
 
void update (Observable arg0, Object arg1)
 
void switchVRMode (VrMode mode)
 
void publishVRContent (boolean hasVRContent)
 

Protected Member Functions

void doFullscreenChange (boolean fullscreen)
 Sets the fullscreen state to this layout controller. More...
 
void beforeFullscreenChange ()
 
void afterFullscreenChange ()
 

Protected Attributes

OoyalaPlayerLayout _layout = null
 
Dialog _fullscreenDialog = null
 
OoyalaPlayerLayout _fullscreenLayout = null
 
OoyalaPlayerControls _inlineControls = null
 
OoyalaPlayerControls _fullscreenControls = null
 
OoyalaPlayerControls _inlineOverlay = null
 
OoyalaPlayerControls _fullscreenOverlay = null
 
OoyalaPlayer _player = null
 
boolean _fullscreenButtonShowing = true
 
List< String > optionList
 
ListView listView
 
AlertDialog ccLanguageDialog
 
boolean ccLanguageDialogCanceled
 
RadioButton ccLanguageDialogUncommittedSelection
 

Detailed Description

This LayoutController is a faster LayoutController that will work only on one specific case: The OoyalaPlayerLayout it controls is a direct child of the Activity's base layout which is a FrameLayout.

This LayoutController uses basic controls and allows additional overlays to be added. Fullscreening is done by simply resizing the OoyalaPlayerLayout to fill the entire screen, which does not trigger a player reload thus causing this to be much faster at Fullscreening than OoyalaPlayerLayoutController.

Constructor & Destructor Documentation

com.ooyala.android.ui.OptimizedOoyalaPlayerLayoutController.OptimizedOoyalaPlayerLayoutController ( OoyalaPlayerLayout  l,
OoyalaPlayer  p 
)

Instantiate a FastOoyalaPlayerLayoutController.

Parameters
lthe layout to use
pthe instantiated player to use
com.ooyala.android.ui.OptimizedOoyalaPlayerLayoutController.OptimizedOoyalaPlayerLayoutController ( OoyalaPlayerLayout  l,
OoyalaPlayer  p,
DefaultControlStyle  dcs 
)

Instantiate a FastOoyalaPlayerLayoutController.

Parameters
lthe layout to use
pthe instantiated player to use
dcsthe DefaultControlStyle to use (AUTO is default controls, NONE has no controls)

Member Function Documentation

void com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController.addVideoView ( View  videoView)
inherited

Insert the video view into the view hierarchy.

Will automatically include other views such as TV Ratings.

Parameters
videoView

Implements com.ooyala.android.ui.LayoutController.

void com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController.afterFullscreenChange ( )
protectedinherited
void com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController.beforeFullscreenChange ( )
protectedinherited
OoyalaPlayerControls com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController.createDefaultControls ( OoyalaPlayerLayout  layout,
boolean  fullscreen 
)
inherited
void com.ooyala.android.ui.OptimizedOoyalaPlayerLayoutController.doFullscreenChange ( boolean  fullscreen)
protected

Sets the fullscreen state to this layout controller.

Parameters
fullscreen
ClosedCaptionsStyle com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController.getClosedCaptionsStyle ( )
inherited
Returns
the current ClosedCaptionsStyle
OoyalaPlayerControls com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController.getControls ( )
inherited
FrameLayout com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController.getLayout ( )
inherited

Get the current active layout.

Returns
the current active layout

Implements com.ooyala.android.ui.LayoutController.

OoyalaPlayerControls com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController.getOverlay ( )
inherited
OoyalaPlayer com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController.getPlayer ( )
inherited

Get the OoyalaPlayer associated with this Controller.

Returns
the OoyalaPlayer
boolean com.ooyala.android.ui.OptimizedOoyalaPlayerLayoutController.isFullscreen ( )
Returns
true if currently in fullscreen, false if not

Implements com.ooyala.android.ui.LayoutController.

boolean com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController.onKeyUp ( int  keyCode,
KeyEvent  event 
)
inherited

Handle the keydown events from OoyalaPlayerLayout.

Parameters
keyCodethe keycode
eventthe event
Returns

Implements com.ooyala.android.ui.LayoutController.

boolean com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController.onTouchEvent ( MotionEvent  event,
OoyalaPlayerLayout  source 
)
inherited

Handle the touch events from OoyalaPlayerLayout.

Parameters
eventthe event
sourcethe layout that created the event
Returns

Implements com.ooyala.android.ui.LayoutController.

void com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController.publishVRContent ( boolean  hasVRContent)
inherited
void com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController.removeVideoView ( )
inherited

Remove any previously added video view, and related items such as the TV Ratings view.

Implements com.ooyala.android.ui.LayoutController.

void com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController.reshowTVRating ( )
inherited

Reshow TV rating (if the current FCCTVRatingConfiguration allows it).

Implements com.ooyala.android.ui.LayoutController.

void com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController.setClosedCaptionsBottomMargin ( int  bottomMargin)
inherited

Set the bottomMargin of closedCaptions view.

Parameters
bottomMarginthe bottom margin to use
void com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController.setClosedCaptionsPresentationStyle ( )
inherited
void com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController.setClosedCaptionsStyle ( ClosedCaptionsStyle  closedCaptionsStyle)
inherited

Set the ClosedCaptionsStyle.

Parameters
closedCaptionsStylethe ClosedCaptionsStyle to use
final void com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController.setFullscreen ( boolean  fullscreen)
inherited

Set the fullscreen state.

Parameters
fullscreentrue for fullscreen, false for inline

Implements com.ooyala.android.ui.LayoutController.

void com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController.setFullscreenButtonShowing ( boolean  showing)
inherited

setFullscreenButtonShowing will enable and disable visibility of the fullscreen button

Implements com.ooyala.android.ui.LayoutController.

void com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController.setFullscreenControls ( OoyalaPlayerControls  controls)
inherited
void com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController.setFullscreenOverlay ( OoyalaPlayerControls  controlsOverlay)
inherited
void com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController.setInlineControls ( OoyalaPlayerControls  controls)
inherited
void com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController.setInlineOverlay ( OoyalaPlayerControls  controlsOverlay)
inherited
void com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController.showClosedCaptionsMenu ( )
inherited

Create and display the list of available languages.

Implements com.ooyala.android.ui.LayoutController.

void com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController.switchVRMode ( VrMode  mode)
inherited
void com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController.update ( Observable  arg0,
Object  arg1 
)
inherited

Member Data Documentation

boolean com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController._fullscreenButtonShowing = true
protectedinherited
OoyalaPlayerControls com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController._fullscreenControls = null
protectedinherited
Dialog com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController._fullscreenDialog = null
protectedinherited
OoyalaPlayerLayout com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController._fullscreenLayout = null
protectedinherited
OoyalaPlayerControls com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController._fullscreenOverlay = null
protectedinherited
OoyalaPlayerControls com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController._inlineControls = null
protectedinherited
OoyalaPlayerControls com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController._inlineOverlay = null
protectedinherited
OoyalaPlayerLayout com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController._layout = null
protectedinherited
OoyalaPlayer com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController._player = null
protectedinherited
AlertDialog com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController.ccLanguageDialog
protectedinherited
boolean com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController.ccLanguageDialogCanceled
protectedinherited
RadioButton com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController.ccLanguageDialogUncommittedSelection
protectedinherited
ListView com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController.listView
protectedinherited
List<String> com.ooyala.android.ui.AbstractOoyalaPlayerLayoutController.optionList
protectedinherited