Note that there are some explanatory texts on larger screens.

plurals
  1. POEmbedding youtube player in GWT (BST Player API)
    primarykey
    data
    text
    <p>I'm developing a GWT application. I need to embed a YouTube video in my application.<br> I've tried BST player API but I wasn't successful in bringing up the video on the player.<br> I've downloaded BST <code>Player.jar</code> and added it to my buildpath, then inherited the following jars in <code>gwtapp.gwt.xml</code>:</p> <pre><code>**inherits name ='com.bramosystems.oss.player.core.Core'** **inherits name ='com.bramosystems.oss.player.youtube.YouTube'** </code></pre> <p>Then I tried the example given on BST page: </p> <pre class="lang-java prettyprint-override"><code>simplePanel = new SimplePanel(); add(simplePanel); simplePanel.setSize("", ""); try { // create the player, specifing URL of media player = new ChromelessPlayer("http://www.youtube.com/watch?v=O3CZFfyed3M", "80%", "350px"); CustomPlayerControl cpc = new CustomPlayerControl(player); FlowPanel fp = new FlowPanel(); fp.add(player); fp.add(cpc); simplePanel.setWidget(fp); // add player and custom control to panel. } catch (PluginVersionException e) { // required Flash plugin version is not available, // alert user possibly providing a link to the plugin download page. simplePanel.setWidget(new HTML(".. some nice message telling the " + "user to download plugin first ..")); } catch(PluginNotFoundException e) { // required Flash plugin not found, display a friendly notice. simplePanel.setWidget(PlayerUtil.getMissingPluginNotice(e.getPlugin())); } </code></pre> <p>I could see the panel with the YouTube player but I couldn't see the video loading nor playing. I've tried <code>player.playMedia()</code> and it was of no help. Any ideas of how to proceed and make the video work?</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload