﻿// JScript File

//var console = (console || {log:function(){alert(arguments[0])}})
var currentDiv = {setStyle:function(){}}

function toggleChapter(id, callFlash) {
    if (callFlash == undefined || callFlash == true) {
        getMovie("videoPlayer").toCue(parseInt(id))
    }
    currentDiv.setStyle('display', 'none')
    currentDiv = $('q'+id)
    currentDiv.setStyle('display', 'block')
}

function toggleChapter1(id, callFlash) {
    if (callFlash == undefined || callFlash == true) {
        getMovie("videoPlayer").toCue(parseInt(id))
    }    
}

function onCue(id) {
    toggleChapter(id, false);
}

function getMovie(movieName) {
    if (navigator.appName.indexOf("Microsoft") != -1) {
        return document[movieName]
    } else {
        return document[movieName]
    }
}

function openTimeline() {
    showTimeline()
}