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

Unified Diff: chrome/browser/history/visit_database.cc

Issue 43067: Merge r11411.... (Closed) Base URL: svn://chrome-svn.corp.google.com/chrome/branches/169/src/
Patch Set: Created 11 years, 9 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
« no previous file with comments | « chrome/browser/history/visit_database.h ('k') | chrome/browser/resources/history.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/history/visit_database.cc
===================================================================
--- chrome/browser/history/visit_database.cc (revision 11412)
+++ chrome/browser/history/visit_database.cc (working copy)
@@ -368,4 +368,16 @@
return true;
}
+bool VisitDatabase::GetStartDate(Time* first_visit) {
+ SQLITE_UNIQUE_STATEMENT(statement, GetStatementCache(),
+ "SELECT MIN(visit_time) FROM visits WHERE visit_time != 0");
+ if (!statement.is_valid() || statement->step() != SQLITE_ROW ||
+ statement->column_int64(0) == 0) {
+ *first_visit = Time::Now();
+ return false;
+ }
+ *first_visit = Time::FromInternalValue(statement->column_int64(0));
+ return true;
+}
+
} // namespace history
« no previous file with comments | « chrome/browser/history/visit_database.h ('k') | chrome/browser/resources/history.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698