-
Notifications
You must be signed in to change notification settings - Fork 6
/
index.html
52 lines (52 loc) · 1.81 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<title>Win95</title>
<script src="js-dos.js"></script>
</head>
<body>
<style>
body {
background-image: url('bliss.jpg');
background-repeat: no-repeat;
background-attachment: fixed;
background-size: cover;
}
#Progress {
width: 100%;
background-color: grey;
}
#Bar {
width: 0%;
height: 30px;
background-color: green;
}
button {
visibility: hidden;
}
</style>
<div id="Progress">
<div id="Bar"></div>
</div>
<center>
<canvas id="jsdos"></canvas>
<br/>
<button onclick="ci.fullscreen()">Fullscreen</button>
</center>
<script>
Dos(document.getElementById("jsdos"), { autolock: true, onprogress: (stage, total, loaded) => {document.getElementById("Bar").style.width = Math.floor(loaded * 99 / total) + "%"}}).ready((fs, main) => {
fs.extract("win95.zip").then(() => {
document.getElementById("Bar").style.height = "0px";
main(["-c", "imgmount d c.img", "-c", "boot c.img"]).then((ci) => {
window.ci = ci;
document.getElementsByTagName("button")[0].style.visibility = 'initial';
ci.simulateKeyPress(32);
document.title = "Win95";
})
});
});
</script>
</body>
</html>