summaryrefslogtreecommitdiffstats
path: root/chrome/browser
diff options
context:
space:
mode:
authorstuartmorgan@chromium.org <stuartmorgan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-03-04 01:09:13 +0000
committerstuartmorgan@chromium.org <stuartmorgan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-03-04 01:09:13 +0000
commit144ae2e69f47b35c964aeac487f1a99e8ef836a4 (patch)
tree816c3a6a7c25c9e982627dd1480eb4163a927fa5 /chrome/browser
parent4bf0a52d9081ac14d348305b284b206af0baccbc (diff)
downloadchromium_src-144ae2e69f47b35c964aeac487f1a99e8ef836a4.zip
chromium_src-144ae2e69f47b35c964aeac487f1a99e8ef836a4.tar.gz
chromium_src-144ae2e69f47b35c964aeac487f1a99e8ef836a4.tar.bz2
WebUI Prefs: Animate the subpage slide-in with padding, rather than margin
This makes it much less likely that the animation will cause a flash of scroll bars. BUG=74869 TEST=Open a subpage; unless the window is only slightly wider than the min page width, there should be no scrollbars. Review URL: http://codereview.chromium.org/6603031 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@76851 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser')
-rw-r--r--chrome/browser/resources/options/options_page.css2
-rw-r--r--chrome/browser/resources/options/options_page.js6
2 files changed, 4 insertions, 4 deletions
diff --git a/chrome/browser/resources/options/options_page.css b/chrome/browser/resources/options/options_page.css
index d04e17d..b8a542b 100644
--- a/chrome/browser/resources/options/options_page.css
+++ b/chrome/browser/resources/options/options_page.css
@@ -253,7 +253,7 @@ html.hide-menu #mainview {
}
.subpage-sheet-container {
- -webkit-transition: 0.25s opacity, 0.1s margin-left, 0.1s margin-right;
+ -webkit-transition: 0.25s opacity, 0.1s padding-left, 0.1s padding-right;
box-sizing: border-box;
min-height: 100%;
position: absolute;
diff --git a/chrome/browser/resources/options/options_page.js b/chrome/browser/resources/options/options_page.js
index 2afa1dc..e7d43c8 100644
--- a/chrome/browser/resources/options/options_page.js
+++ b/chrome/browser/resources/options/options_page.js
@@ -852,14 +852,14 @@ cr.define('options', function() {
container.hidden = false;
if (isSubpage) {
var computedStyle = window.getComputedStyle(container);
- container.style.WebkitMarginStart =
- parseInt(computedStyle.WebkitMarginStart, 10) + 100 + 'px';
+ container.style.WebkitPaddingStart =
+ parseInt(computedStyle.WebkitPaddingStart, 10) + 100 + 'px';
}
// Separate animating changes from the removal of display:none.
window.setTimeout(function() {
container.classList.remove('transparent');
if (isSubpage)
- container.style.WebkitMarginStart = '';
+ container.style.WebkitPaddingStart = '';
});
} else {
var self = this;