diff options
Diffstat (limited to 'chrome/browser/resources/history/history.js')
-rw-r--r-- | chrome/browser/resources/history/history.js | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/chrome/browser/resources/history/history.js b/chrome/browser/resources/history/history.js index 96225d7..85f5d4bf 100644 --- a/chrome/browser/resources/history/history.js +++ b/chrome/browser/resources/history/history.js @@ -658,10 +658,16 @@ HistoryView.prototype.displayResults_ = function() { } var searchResults = createElementWithClassName('ol', 'search-results'); - for (var i = 0, visit; visit = results[i]; i++) { - if (!visit.isRendered) { - searchResults.appendChild(visit.getResultDOM(true)); - this.setVisitRendered_(visit); + if (results.length == 0) { + var noResults = document.createElement('div'); + noResults.textContent = loadTimeData.getString('noresults'); + searchResults.appendChild(noResults); + } else { + for (var i = 0, visit; visit = results[i]; i++) { + if (!visit.isRendered) { + searchResults.appendChild(visit.getResultDOM(true)); + this.setVisitRendered_(visit); + } } } this.resultDiv_.appendChild(searchResults); |