|
Java DTV API 1.3 18-Nov-2009 |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.sun.dtv.lwuit.Component
com.sun.dtv.lwuit.MediaComponent
public class MediaComponent
A component allowing us to embed and control rich media content.
| Field Summary |
|---|
| Fields inherited from class com.sun.dtv.lwuit.Component |
|---|
BOTTOM, BRB_CENTER_OFFSET, BRB_CONSTANT_ASCENT, BRB_CONSTANT_DESCENT, BRB_OTHER, CENTER, LEFT, RIGHT, TOP |
| Fields inherited from interface com.sun.dtv.ui.Animated |
|---|
ALTERNATING, LOOP, REPEATING |
| Constructor Summary | |
|---|---|
MediaComponent(Player player)
Creates a new instance of MediaComponent. |
|
| Method Summary | |
|---|---|
void |
paint(Graphics g)
This method paints the Component on the screen, it should be overriden by subclasses to perform custom drawing or invoke the UI API's to let the PLAF perform the rendering. |
void |
paintBackgrounds(Graphics g)
This method paints all the parents Components Background. |
void |
setHeight(int height)
Sets the Component height, this method is exposed for the purpose of external layout managers and should not be invoked directly. |
void |
setVisible(boolean visible)
Display the embedded media component. |
void |
setWidth(int width)
Sets the Component width, this method is exposed for the purpose of external layout managers and should not be invoked directly. |
void |
setX(int x)
Sets the Component x location relative to the parent container, this method is exposed for the purpose of external layout managers and should not be invoked directly. |
void |
setY(int y)
Sets the Component y location relative to the parent container, this method is exposed for the purpose of external layout managers and should not be invoked directly. |
void |
startMedia()
Start media playback implicitly setting the component to visible. |
void |
stopMedia()
Stop media playback. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public MediaComponent(Player player)
player - the media player| Method Detail |
|---|
public void paint(Graphics g)
Component
paint in interface Animationpaint in class Componentg - the component graphicspublic void paintBackgrounds(Graphics g)
Component
paintBackgrounds in class Componentg - the graphics objectpublic void setX(int x)
Component
setX in class Componentx - the current x coordinate of the components originComponent.getX()public void setY(int y)
Component
setY in class Componenty - the current y coordinate of the components originComponent.getY()public void setWidth(int width)
Component
setWidth in class Componentwidth - the width of the componentComponent.getWidth(),
Component.setPreferredSize(com.sun.dtv.lwuit.geom.Dimension)public void setHeight(int height)
Component
setHeight in class Componentheight - the height of the componentComponent.getHeight(),
Component.setPreferredSize(com.sun.dtv.lwuit.geom.Dimension)public void setVisible(boolean visible)
setVisible in class Componentvisible - true to display, false to hide
public void startMedia()
throws MediaException
MediaException - if starting media fails
public void stopMedia()
throws MediaException
MediaException - if stopping media fails
|
Java DTV API 1.3 18-Nov-2009 |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||