| Index: chrome/browser/history/text_database_manager.cc
|
| ===================================================================
|
| --- chrome/browser/history/text_database_manager.cc (revision 50158)
|
| +++ chrome/browser/history/text_database_manager.cc (working copy)
|
| @@ -28,18 +28,12 @@
|
| // The number of database files we will be attached to at once.
|
| const int kCacheDBSize = 5;
|
|
|
| -std::string ConvertStringForIndexer(const std::wstring& input) {
|
| +std::string ConvertStringForIndexer(
|
| + const std::wstring& input) {
|
| // TODO(evanm): other transformations here?
|
| return WideToUTF8(CollapseWhitespace(input, false));
|
| }
|
|
|
| -#if !defined(OS_WIN) // string16 == wstring on Windows.
|
| -std::string ConvertStringForIndexer(const string16& input) {
|
| - // TODO(evanm): other transformations here?
|
| - return UTF16ToUTF8(CollapseWhitespace(input, false));
|
| -}
|
| -#endif
|
| -
|
| // Data older than this will be committed to the full text index even if we
|
| // haven't gotten a title and/or body.
|
| const int kExpirationSec = 20;
|
| @@ -64,9 +58,9 @@
|
| title_ = ttl;
|
| }
|
|
|
| -void TextDatabaseManager::PageInfo::set_body(const string16& bdy) {
|
| +void TextDatabaseManager::PageInfo::set_body(const std::wstring& bdy) {
|
| if (bdy.empty()) // Make the body nonempty when we set it for EverybodySet.
|
| - body_ = ASCIIToUTF16(" ");
|
| + body_ = L" ";
|
| else
|
| body_ = bdy;
|
| }
|
| @@ -215,7 +209,7 @@
|
| }
|
|
|
| AddPageData(url, url_row.id(), visit.visit_id, visit.visit_time,
|
| - title, string16());
|
| + title, std::wstring());
|
| return; // We don't know about this page, give up.
|
| }
|
|
|
| @@ -232,7 +226,7 @@
|
| }
|
|
|
| void TextDatabaseManager::AddPageContents(const GURL& url,
|
| - const string16& body) {
|
| + const std::wstring& body) {
|
| RecentChangeList::iterator found = recent_changes_.Peek(url);
|
| if (found == recent_changes_.end()) {
|
| // This page is not in our cache of recent pages. This means that the page
|
| @@ -272,7 +266,7 @@
|
| VisitID visit_id,
|
| Time visit_time,
|
| const std::wstring& title,
|
| - const string16& body) {
|
| + const std::wstring& body) {
|
| TextDatabase* db = GetDBForTime(visit_time, true);
|
| if (!db)
|
| return false;
|
|
|