ccd0
11 years ago
7 changed files with 47 additions and 29 deletions
@ -0,0 +1,14 @@ |
|||||
|
// Scripts obtain settings by calling this function
|
||||
|
function setting(name) { |
||||
|
return JSON.parse(localStorage[name]); |
||||
|
} |
||||
|
|
||||
|
// Default settings
|
||||
|
function setDefault(name, value) { |
||||
|
if (!(name in localStorage)) { |
||||
|
localStorage[name] = JSON.stringify(value); |
||||
|
} |
||||
|
} |
||||
|
setDefault("videoexpand", true); |
||||
|
setDefault("videohover", false); |
||||
|
setDefault("videomuted", false); |
@ -1,7 +1,5 @@ |
|||||
window.onload = function() { |
if (window.addEventListener) window.addEventListener("load", function(e) { |
||||
settingsPanel.style.cssFloat = "right"; |
|
||||
document.body.insertBefore(settingsPanel, document.body.firstChild); |
|
||||
var video = document.getElementsByTagName("video")[0]; |
var video = document.getElementsByTagName("video")[0]; |
||||
video.muted = setting("videomuted"); |
video.muted = setting("videomuted"); |
||||
video.play(); |
video.play(); |
||||
}; |
}, false); |
||||
|
@ -0,0 +1,9 @@ |
|||||
|
body { |
||||
|
background: black; |
||||
|
color: white; |
||||
|
} |
||||
|
video { |
||||
|
display: block; |
||||
|
margin-left: auto; |
||||
|
margin-right: auto; |
||||
|
} |
Loading…
Reference in new issue