From 258087e82f293b4770d9d36d0d3bc6a90cf797aa Mon Sep 17 00:00:00 2001 From: Astro Date: Mon, 15 Nov 2010 01:41:31 +0100 Subject: [PATCH] play-resources.js & Play button --- content/static/script/play-resources.js | 123 ++++++++++++++++++++++++ content/static/style/default.css | 5 + xsl/header.xsl | 5 + xsl/xhtml5.xsl | 30 +----- 4 files changed, 135 insertions(+), 28 deletions(-) create mode 100644 content/static/script/play-resources.js diff --git a/content/static/script/play-resources.js b/content/static/script/play-resources.js new file mode 100644 index 000000000..94224ac25 --- /dev/null +++ b/content/static/script/play-resources.js @@ -0,0 +1,123 @@ +function addButton(container, res) { + var button = $('▶ Play'); + button.click(function() { + button.remove(); + + addPlayer(container, res); + }); + container.append(button); +} + +function addPlayer(container, res) { + var types = res.map(function(res) { + return res.type; + }); + /* Can we have