Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(93)

Side by Side Diff: third_party/WebKit/LayoutTests/scrollbars/hidden-scrollbars-invisible.html

Issue 2509843004: Disable overlay scrollbars to hide them on non-Mac. (Closed)
Patch Set: Renamed to shouldDisableInvisibleScrollbars Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 <!DOCTYPE html>
2 <script>
3 if (window.internals) {
4 internals.settings.setOverlayScrollbarsEnabled(true);
5 internals.settings.setMockScrollbarsEnabled(true);
6 }
7 </script>
8 <div id="div" style="overflow: scroll; width: 200px; height: 200px;">
9 <div style="background-color: green; height: 3000px; width: 100px"></div>
10 </div>
11 <iframe srcdoc="<div style='background-color: red; height: 3000px; width: 100px' ></div>"
12 id="iframe",
13 width="200",
14 height="200"></iframe>
15 <script>
16 window.onload = function() {
17 if (window.internals) {
18 internals.settings.setOverlayScrollbarsEnabled(true);
19
20 var div = document.querySelector('#div');
21 var iframe = document.querySelector('#iframe');
22 internals.setScrollbarVisibilityInScrollableArea(div, true);
23 internals.setScrollbarVisibilityInScrollableArea(
24 iframe.contentDocument, true);
25
26 internals.setScrollbarVisibilityInScrollableArea(div, false);
27 internals.setScrollbarVisibilityInScrollableArea(
28 iframe.contentDocument, false);
29 }
30 }
31 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698