Skip to content

Instantly share code, notes, and snippets.

@basicxman
Created December 23, 2011 22:29
Show Gist options
  • Select an option

  • Save basicxman/1515553 to your computer and use it in GitHub Desktop.

Select an option

Save basicxman/1515553 to your computer and use it in GitHub Desktop.
window.streamCallback = (data) ->
if $.streams is undefined or data.version >= $.streams.version
$.streams = data
executeStreams()
executeStreams = ->
for stream in $.streams.streams
elm = $("#blank-stream").clone()
elm.attr("id", "stream-#{stream.id}")
elm.html(stream.embed)
elm.appendTo("#stream-container")
elm.dialog({
title: stream.name
})
loadStream = ->
$.getScript("js/streams.js")
jQuery ->
loadStream()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment