OLD | NEW |
(Empty) | |
| 1 <!DOCTYPE HTML> |
| 2 <style> |
| 3 /* Let's get this party started */ |
| 4 ::-webkit-scrollbar { |
| 5 width: 10px; |
| 6 height: 10px; |
| 7 } |
| 8 |
| 9 /* Track */ |
| 10 ::-webkit-scrollbar-track { |
| 11 -webkit-box-shadow: inset 0 0 6px rgba(0,0,0,0.3); |
| 12 -webkit-border-radius: 10px; |
| 13 border-radius: 10px; |
| 14 } |
| 15 |
| 16 /* Handle */ |
| 17 ::-webkit-scrollbar-thumb { |
| 18 -webkit-border-radius: 10px; |
| 19 border-radius: 10px; |
| 20 background: rgba(255,0,0,0.8); |
| 21 -webkit-box-shadow: inset 0 0 6px rgba(0,0,0,0.5); |
| 22 } |
| 23 |
| 24 </style> |
| 25 <iframe src="resources/scrollable-iframe.html"></iframe> |
| 26 <iframe src="resources/scrollable-iframe.html"></iframe> |
| 27 <script> |
| 28 if (window.testRunner) |
| 29 testRunner.waitUntilDone(); |
| 30 var styleElement = document.createElement("style"); |
| 31 var sheet = document.head.appendChild(styleElement).sheet; |
| 32 function addStyle() { |
| 33 function addRule(selector, css){ |
| 34 var propText = Object.keys(css).map(function(p){ |
| 35 return p+":"+css[p] |
| 36 }).join(";"); |
| 37 sheet.insertRule(selector + "{" + propText + "}", sheet.cssRules.length); |
| 38 }; |
| 39 addRule("::-webkit-scrollbar", {width: "20px",height: "25px"}); |
| 40 if (window.testRunner) |
| 41 testRunner.notifyDone(); |
| 42 } |
| 43 setTimeout(function(){ addStyle(); }, 100); |
| 44 </script> |
OLD | NEW |