summaryrefslogtreecommitdiffstats
path: root/third_party/WebKit/LayoutTests/fast/events/panScroll-nested-divs-forbidden.html
blob: 63ed8a0356ecca571ab81d904090b43e1a618316 (plain)
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>
<head>
<style type="text/css">
div {
    line-height: 50px;
}
#outerdiv {
    overflow:auto;
    border: 2px solid #000FFF;
}
#innerdiv {
    overflow:auto;
    border: 2px solid #000000;
    width: 121%;
    padding: 5px;
}
</style>
<script src="../js/resources/js-test-pre.js"></script>
<script src="./resources/panScroll.js"></script>
<script>
function start()
{
  outerdiv = $('outerdiv');

  testPanScroll({
    'clickOrDrag': 'drag',
    'endX': 225,
    'endY': 75,
    'finishTest': function() {
      shouldNotBe('outerdiv.scrollLeft', '0');
      shouldBeZero('outerdiv.scrollTop');
    },
    'scrollable': outerdiv,
    'startX': 150,
    'startY': 150,
  });
}
</script>
</head>
<body onload="start()">
<div id="outerdiv">
    <p>Top of outer div.</p>
    <div id="innerdiv">
        <p>Inner div.</p>
    </div>
    <p>Bottom of outer div.</p>
</div>
<p>Test for <a href="http://crbug.com/232965">bug 232965</a> This tests that vertical pan scrolling does not propagate from the inner div to the outer div when the outer div has no vertical overflow.</p>
<div id="console"></div>
</body>
</html>