function getFlashMovieObject(movieName)
{
  if (window.document[movieName]) 
  {
      return window.document[movieName];
  }
  if (navigator.appName.indexOf("Microsoft Internet")==-1)
  {
    if (document.embeds && document.embeds[movieName])
      return document.embeds[movieName]; 
  }
  else // if (navigator.appName.indexOf("Microsoft Internet")!=-1)
  {
    return document.getElementById(movieName);
  }
}
function SendDataToFlashMovie(movieNameHere)
{
     var flashMovie=getFlashMovieObject(movieNameHere);
     flashMovie.SetVariable("/:message", 
          document.controller.Data.value);
}
function StopFlashMovie()
{
    var flashMovie=getFlashMovieObject("myFlashMovie");
    flashMovie.StopPlay();
}
function PlayFlashMovie(movieNameHere)
{
    var flashMovie=getFlashMovieObject(movieNameHere);
    flashMovie.Play();
    //embed.nativeProperty.anotherNativeMethod();
}

function RewindFlashMovie(movieNameHere)
{
    var flashMovie=getFlashMovieObject(movieNameHere);
    flashMovie.Rewind();
}
function ActorHeight(divId, newWidth, newHeight) {
	$("#"+divId).stop().animate({
		opacity: 1,
		height: newHeight,
		width: newWidth
	  }, 500, function() {
	    // Animation complete.
 	});
}
function ActorClose(divId) {
	$("#"+divId).hide();
}
function ActorShow(divId) {
	ActorHeight("polyagents-logo", 250, 310);
	//PlayFlashMovie(BarscoActor)
	$("#"+divId).show();
        $("#"+divId).hover(function() {
            $(this).css({backgroundPosition: '-250px 0px'});
        },	function() {
            $(this).css({backgroundPosition: '0px 0px'});
        });	
	
	
}
function ActorRewind() {
	document.location.reload();
	//$("#"+divId).load(fileName);
}
