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

Unified Diff: chrome/browser/resources/ntp4/tile_page.js

Issue 7833021: [ntp4] Add a 'Manage Bookmarks' link at the top of the Bookmarks page. Also right-align links. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 3 months 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/resources/ntp4/tile_page.js
===================================================================
--- chrome/browser/resources/ntp4/tile_page.js (revision 99605)
+++ chrome/browser/resources/ntp4/tile_page.js (working copy)
@@ -319,6 +319,12 @@
// the tile page padding.
var MIN_WIDE_MARGIN = 18;
+ // Extra space to allow at the bottom of a tilegrid when setting the
+ // min-height property. This is a bit of a hack to allow pages to insert
+ // small content at the bottom.
+ // TODO(csilv): Remove the need for this.
+ var TILE_GRID_EXTRA_PADDING = 40;
Evan Stade 2011/09/05 01:59:20 can you do this as a function on TilePage which ch
csilv 2011/09/06 05:33:33 Done.
+
/**
* Creates a new TilePage object. This object contains tiles and controls
* their layout.
@@ -486,6 +492,7 @@
this.tileElements_[index]);
}
this.calculateLayoutValues_();
+ this.heightChanged_();
this.positionTile_(index);
},
@@ -755,7 +762,8 @@
// a flex box, and the tile grid could be box-flex: 1, but this exposes a
// bug where repositioning tiles will cause the scroll position to reset.
this.tileGrid_.style.minHeight = (this.clientHeight -
- this.tileGrid_.offsetTop) + 'px';
+ this.tileGrid_.offsetTop - this.content_.offsetTop -
+ TILE_GRID_EXTRA_PADDING) + 'px';
},
/**

Powered by Google App Engine
This is Rietveld 408576698