回答編集履歴
1
コードの誤り
answer
CHANGED
@@ -10,7 +10,7 @@
|
|
10
10
|
```
|
11
11
|
```Javascript
|
12
12
|
// 変更後
|
13
|
-
function
|
13
|
+
function myResize() {
|
14
14
|
var tgt = $('#slideshow');
|
15
15
|
tgt.height($('#slideshow img:first').height());
|
16
16
|
$('#slideshow img').each(function(){
|
@@ -22,12 +22,12 @@
|
|
22
22
|
|
23
23
|
$(function() {
|
24
24
|
setInterval( "slideSwitch()", 4000 );
|
25
|
-
|
25
|
+
myResize();
|
26
26
|
|
27
27
|
var timer = null;
|
28
28
|
$(window).on('resize', function(){
|
29
29
|
clearTimeout(timer);
|
30
|
-
timer = setTimeout(
|
30
|
+
timer = setTimeout(myResize,200);
|
31
31
|
});
|
32
32
|
});
|
33
33
|
```
|