From: krome
Date: Tue, 28 Sep 2010 14:17:10 +0000 (+0200)
Subject: Lastfm support added
X-Git-Tag: v0.1~26^2~4
X-Git-Url: http://git.khamidou.com/?a=commitdiff_plain;h=60fa4589a35f83cc6bacafb861d1be8103dae3fa;p=popcorn-js.git
Lastfm support added
---
diff --git a/demos/semantic_video/index.html b/demos/semantic_video/index.html
index 8b9e05c..cdcb07a 100644
--- a/demos/semantic_video/index.html
+++ b/demos/semantic_video/index.html
@@ -85,7 +85,7 @@
@@ -118,7 +118,7 @@
};
Popcorn.VideoManager.prototype.loaded = function() {
for (var i in this.commandObjects) {
- if (this.commandObjects[i].name === 'flickr' || this.commandObjects[i].name === 'footnote' || this.commandObjects[i].name === 'location' || this.commandObjects[i].name === 'twitter' || this.commandObjects[i].name === 'wiki') {
+ if (this.commandObjects[i].name === 'flickr' || this.commandObjects[i].name === 'footnote' || this.commandObjects[i].name === 'location' || this.commandObjects[i].name === 'twitter' || this.commandObjects[i].name === 'wiki' || this.commandObjects[i].name === 'lastfm') {
this.commandObjects[i].extension.image = createImage("images/overlay/" + this.commandObjects[i].name + ".png");
this.commandObjects[i].extension.onIn = function() {
this.image.setAttribute('style', "display:inline");
@@ -226,6 +226,11 @@
+
+
diff --git a/demos/semantic_video/xml/webMadeMovies.xml b/demos/semantic_video/xml/webMadeMovies.xml
index 3ff05ac..0662c60 100644
--- a/demos/semantic_video/xml/webMadeMovies.xml
+++ b/demos/semantic_video/xml/webMadeMovies.xml
@@ -179,6 +179,10 @@
Celine Celines
+
+
+
+
';
+ htmlString += '
Similar
';
+ jQuery.each(data.artist.similar.artist, function(i,val) {
+ htmlString += '- '+ this.name +'
';
+ });
+ htmlString += '
';
+ target.innerHTML = htmlString;
+ }
+ );
+
+ this.target = target;
+ this.onIn = function() {
+ this.target.setAttribute('style', 'display:inline');
+ };
+ this.onOut = function() {
+ this.target.setAttribute('style', 'display:none');
+ };
+ this.preload = function() {}; // Probably going to need to preload this.
+ };
+
////////////////////////////////////////////////////////////////////////////
// Twitter Command
////////////////////////////////////////////////////////////////////////////
@@ -937,6 +981,11 @@
create: function(name, params, text, videoManager) {
return new Popcorn.WikiCommand(name, params, text, videoManager);
}
+ },
+ lastfm: {
+ create: function(name, params, text, videoManager) {
+ return new Popcorn.LastfmCommand(name, params, text, videoManager);
+ }
},
lowerthird: {
create: function(name, params, text, videoManager) {