summaryrefslogtreecommitdiffstats
path: root/third_party/WebKit/LayoutTests/fast/repaint/block-selection-gap-stale-cache.html
blob: f13b443d402a5951c99292395a668b53e573fb89 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
<head>
    <style>
        ::selection { background-color: red; }
    </style>
    <script type="text/javascript" charset="utf-8">
    function runTest()
    {
        sel.empty();
    }
    </script>
</head>
<body onload="runTest()">
<div><div id="target" style="display: inline-block; width: 100px; height: 50px;"></div><br></div>&nbsp;
<script>
    var sel = getSelection();
    var target = document.getElementById("target");

    sel.setBaseAndExtent(target, 0, target.parentElement.nextSibling, 0);
    document.body.offsetTop;
    target.style.height = "100px";
</script>