am 36ea7a3d: remove the dummy sidenav from samples before populating the real list. Also make the line numbers hidden before they get moved to avoid some jankyness during load.

* commit '36ea7a3d74c68d62a5d081401b887e848370f6d8':
  remove the dummy sidenav from samples before populating the real list. Also make the line numbers hidden before they get moved to avoid some jankyness during load.
This commit is contained in:
Scott Main 2013-10-30 16:41:42 -07:00 committed by Android Git Automerger
commit 70120d0bff
2 changed files with 9 additions and 0 deletions

View file

@ -2507,6 +2507,9 @@ pre#codesample-block {
background:transparent;
border:none;
}
pre#codesample-block a.number {
display:none;
}
pre#codesample-block .code-line:hover {
background:#e7e7e7;
}

View file

@ -2802,6 +2802,12 @@ function init_default_samples_navtree(toroot) {
$.getScript(toRoot + 'samples_navtree_data.js', function(data, textStatus, jqxhr) {
// when the file is loaded, initialize the tree
if(jqxhr.status === 200) {
// hack to remove the "about the samples" link then put it back in
// after we nuke the list to remove the dummy static list of samples
var $firstLi = $("#nav.samples-nav > li:first-child").clone();
$("#nav.samples-nav").empty();
$("#nav.samples-nav").append($firstLi);
init_google_navtree2("nav.samples-nav", SAMPLES_NAVTREE_DATA);
highlightSidenav();
resizeNav();