Skip to content

Commit 3ac5038

Browse files
committed
[test] update manual window case for window dimension test
1 parent dda5047 commit 3ac5038

File tree

2 files changed

+34
-2
lines changed

2 files changed

+34
-2
lines changed

test/manual/window/index.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
<script>
1111
var gui = nw;
1212
var win;
13-
gui.Window.open('popup.html', {
13+
gui.Window.open('newpop.html', {
1414
x: 100, y: 100, width: 200, height: 300
1515
}, function(w) { win = w;
1616

@@ -78,7 +78,7 @@
7878
<br/>
7979
<button onclick="win.moveBy(10, 20)">moveBy(10, 20)</button>
8080
<br/>
81-
<button onclick="win.resizeTo(100, 100)">resizeTo(100, 100)</button>
81+
<button onclick="win.resizeTo(180, 180)">resizeTo(180, 180)</button>
8282
<br/>
8383
<button onclick="win.resizeBy(10, 20)">resizeBy(10, 20)</button>
8484
<br/>

test/manual/window/newpop.html

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
<!DOCTYPE html>
2+
<html>
3+
<head>
4+
<title>5093 as a menu window</title>
5+
<meta charset="UTF-8">
6+
<style>
7+
html,
8+
body {
9+
width: 100%;
10+
height: 100%;
11+
margin: 0;
12+
padding: 0;
13+
background-color: blue;
14+
}
15+
#yellow {
16+
color: black;
17+
background-color: yellow;
18+
width: 800px;
19+
height: 600px;
20+
}
21+
</style>
22+
</head>
23+
<body>
24+
<div id="yellow"></div>
25+
</body>
26+
<script>
27+
window.onload = window.onresize = function() {
28+
var yellow = document.getElementById('yellow');
29+
yellow.innerHTML = window.innerWidth + ", " + window.innerHeight + ' - inner size';
30+
}
31+
</script>
32+
</html>

0 commit comments

Comments
 (0)