diff options
author | phajdan.jr@chromium.org <phajdan.jr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-08-06 19:46:57 +0000 |
---|---|---|
committer | phajdan.jr@chromium.org <phajdan.jr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-08-06 19:46:57 +0000 |
commit | bbe192b6e32035bae275f798bd495d136a1a1d68 (patch) | |
tree | 4e094f9446b48dcf01d331b44e298fd807f61fd7 /chrome/browser/history/thumbnail_database.cc | |
parent | 145db1f5370109e0abcd324c37424dded8a501df (diff) | |
download | chromium_src-bbe192b6e32035bae275f798bd495d136a1a1d68.zip chromium_src-bbe192b6e32035bae275f798bd495d136a1a1d68.tar.gz chromium_src-bbe192b6e32035bae275f798bd495d136a1a1d68.tar.bz2 |
Revert "Replace --top-sites flag with --no-top-sites flag. TopSites becomes the default."
Introduced new crashes.
TBR=nshkrob
Review URL: http://codereview.chromium.org/3026059
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@55268 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/history/thumbnail_database.cc')
-rw-r--r-- | chrome/browser/history/thumbnail_database.cc | 18 |
1 files changed, 5 insertions, 13 deletions
diff --git a/chrome/browser/history/thumbnail_database.cc b/chrome/browser/history/thumbnail_database.cc index 979accf..8bf203d 100644 --- a/chrome/browser/history/thumbnail_database.cc +++ b/chrome/browser/history/thumbnail_database.cc @@ -130,7 +130,7 @@ sql::InitStatus ThumbnailDatabase::OpenDatabase(sql::Connection* db, bool ThumbnailDatabase::InitThumbnailTable() { if (!db_.DoesTableExist("thumbnails")) { - if (!CommandLine::ForCurrentProcess()-> HasSwitch(switches::kNoTopSites)) { + if (CommandLine::ForCurrentProcess()-> HasSwitch(switches::kTopSites)) { use_top_sites_ = true; return true; } @@ -231,10 +231,8 @@ void ThumbnailDatabase::SetPageThumbnail( const SkBitmap& thumbnail, const ThumbnailScore& score, base::Time time) { - if (use_top_sites_) { - LOG(WARNING) << "Use TopSites instead."; + if (use_top_sites_) return; // Not possible after migration to TopSites. - } if (!thumbnail.isNull()) { bool add_thumbnail = true; @@ -288,10 +286,8 @@ void ThumbnailDatabase::SetPageThumbnail( bool ThumbnailDatabase::GetPageThumbnail(URLID id, std::vector<unsigned char>* data) { - if (use_top_sites_) { - LOG(WARNING) << "Use TopSites instead."; + if (use_top_sites_) return false; // Not possible after migration to TopSites. - } sql::Statement statement(db_.GetCachedStatement(SQL_FROM_HERE, "SELECT data FROM thumbnails WHERE url_id=?")); @@ -307,10 +303,8 @@ bool ThumbnailDatabase::GetPageThumbnail(URLID id, } bool ThumbnailDatabase::DeleteThumbnail(URLID id) { - if (use_top_sites_) { - LOG(WARNING) << "Use TopSites instead."; + if (use_top_sites_) return true; // Not possible after migration to TopSites. - } sql::Statement statement(db_.GetCachedStatement(SQL_FROM_HERE, "DELETE FROM thumbnails WHERE url_id = ?")); @@ -323,10 +317,8 @@ bool ThumbnailDatabase::DeleteThumbnail(URLID id) { bool ThumbnailDatabase::ThumbnailScoreForId(URLID id, ThumbnailScore* score) { - if (use_top_sites_) { - LOG(WARNING) << "Use TopSites instead."; + if (use_top_sites_) return false; // Not possible after migration to TopSites. - } // Fetch the current thumbnail's information to make sure we // aren't replacing a good thumbnail with one that's worse. |