var noiser = new Object();

noiser.onInit=function()
{
  this.started=false;
  this.flash=$(this.id);
  this.flash.SetVariable("method:setUrl", this.url);
  this.flash.SetVariable("enabled", "true");
  this.flash.SetVariable("method:play", "");
}

noiser.onUpdate=function()
{
  if ((! this.started) && (this.bytesLoaded == this.bytesTotal))
  // File is loaded, run animation
  {
    this.started=true;
    animateButtons()
  }
  if (this.started && (! this.isPlaying))
  // We've done
  {
    this.flash.SetVariable("enabled", "false");
  }
}

function makeNoiseControl(id, url)
{
  noiser.id=id;
  noiser.url=url;
  noiser.active=true;
}
