mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-14 15:37:55 +00:00
25 lines
615 B
HTML
25 lines
615 B
HTML
<html>
|
|
<head>
|
|
<script type="text/javascript">
|
|
var theme = {
|
|
id: "test",
|
|
name: "Test Background",
|
|
headerURL: "http://example.com/firefox/personas/01/header.jpg",
|
|
footerURL: "http://example.com/firefox/personas/01/footer.jpg",
|
|
textcolor: "#fff",
|
|
accentcolor: "#6b6b6b"
|
|
};
|
|
|
|
function setTheme(node) {
|
|
node.setAttribute("data-browsertheme", JSON.stringify(theme));
|
|
var event = document.createEvent("Events");
|
|
event.initEvent("InstallBrowserTheme", true, false);
|
|
node.dispatchEvent(event);
|
|
}
|
|
</script>
|
|
</head>
|
|
<body>
|
|
<a id="theme-install" href="#" onclick="setTheme(this)">Install</a>
|
|
</body>
|
|
</html>
|