summaryrefslogtreecommitdiffstats
path: root/chrome/browser
diff options
context:
space:
mode:
authoraa@chromium.org <aa@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-10-18 21:45:19 +0000
committeraa@chromium.org <aa@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-10-18 21:45:19 +0000
commit3eb923c081d9e23654f6f618b0ba553fb7f2bcfa (patch)
tree43ce971adad8759e110c164d80c6e8f8b5122867 /chrome/browser
parent2a8741c8a8a9e8be6eb74809b8280dba76219f2d (diff)
downloadchromium_src-3eb923c081d9e23654f6f618b0ba553fb7f2bcfa.zip
chromium_src-3eb923c081d9e23654f6f618b0ba553fb7f2bcfa.tar.gz
chromium_src-3eb923c081d9e23654f6f618b0ba553fb7f2bcfa.tar.bz2
Scroll new apps into view when they are installed.
Also, minor adjustment to spacing at bottom of scrollable areas. BUG=59235 TEST=Install enough apps so that the apps section scrolls, and then install one more. Apps section should scroll to bottom so that you can see the animation happen. Review URL: http://codereview.chromium.org/3771007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@62977 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser')
-rw-r--r--chrome/browser/resources/ntp/apps.css4
-rw-r--r--chrome/browser/resources/ntp/apps.js3
2 files changed, 7 insertions, 0 deletions
diff --git a/chrome/browser/resources/ntp/apps.css b/chrome/browser/resources/ntp/apps.css
index 3e2f8f9..b4932df 100644
--- a/chrome/browser/resources/ntp/apps.css
+++ b/chrome/browser/resources/ntp/apps.css
@@ -6,6 +6,10 @@
max-width: 780px; /* (124 + margin * 2) * 6 */
}
+#apps-maxiview {
+ padding-bottom: 10px;
+}
+
html.apps-promo-visible #apps-content {
max-width: 650px; /* (124 + margin * 2) * 5 */
}
diff --git a/chrome/browser/resources/ntp/apps.js b/chrome/browser/resources/ntp/apps.js
index a3ba154..f6b5bfc 100644
--- a/chrome/browser/resources/ntp/apps.js
+++ b/chrome/browser/resources/ntp/apps.js
@@ -237,6 +237,9 @@ var apps = (function() {
div.setAttribute('new', 'new');
// Delay changing the attribute a bit to let the page settle down a bit.
setTimeout(function() {
+ // Make sure the new icon is scrolled into view.
+ document.body.scrollTop = document.body.scrollHeight;
+
// This will trigger the 'bounce' animation defined in apps.css.
div.setAttribute('new', 'installed');
}, 500);