Chromium Code Reviews| Index: chrome/browser/resources/extensions/extension_list.js |
| diff --git a/chrome/browser/resources/extensions/extension_list.js b/chrome/browser/resources/extensions/extension_list.js |
| index 7d6187ae2b76e2f41357402194d01065490b3563..9749cc1036370a26276b57d9a6c3003a6d22f301 100644 |
| --- a/chrome/browser/resources/extensions/extension_list.js |
| +++ b/chrome/browser/resources/extensions/extension_list.js |
| @@ -59,8 +59,8 @@ cr.define('options', function() { |
| // the way at the top. That way it is clear that there are more elements |
| // above the element being scrolled to. |
| var scrollFudge = 1.2; |
| - document.documentElement.scrollTop = $(idToHighlight).offsetTop - |
| - scrollFudge * $(idToHighlight).clientHeight; |
| + var scrollTop = $(idToHighlight).offsetTop - scrollFudge * $(idToHighlight).clientHeight; |
|
Dan Beam
2013/11/11 23:46:46
80 col wrap
|
| + setScrollTopForDocument(document, scrollTop); |
| } |
| if (this.data_.extensions.length == 0) |
| @@ -336,7 +336,7 @@ cr.define('options', function() { |
| var pad = parseInt(getComputedStyle(node, null).marginTop, 10); |
| if (!isNaN(pad)) |
| topScroll -= pad / 2; |
| - document.documentElement.scrollTop = topScroll; |
| + setScrollTopForDocument(document, topScroll); |
| } |
| }, |
| }; |