2
0
MasterPassword/Site/2013-05/js/main.js

26 lines
617 B
JavaScript
Raw Permalink Normal View History

2013-06-02 23:12:25 +00:00
$(function(){
$.stellar();
window.onscroll = function() {
document.getElementById("scrollDown").style.opacity = Math.max(0, 200 - window.scrollY) / 200;
};
if (document.location.hash == "#video")
toggleMovie();
$("video")[0].addEventListener("playing", function() {
$(this).parents().find(".fallback").hide();
}, true);
2013-06-02 23:12:25 +00:00
});
function toggleMovie() {
if ($("header").hasClass("play")) {
$("header").removeClass("play");
$("header video")[0].pause();
} else {
$("header").addClass("play");
$("header video")[0].play();
}
}