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

Side by Side Diff: chrome/browser/history/top_sites.h

Issue 6813040: Add TopSites::GetTemporaryThumbnailScore(). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: address comments Created 9 years, 8 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | chrome/browser/history/top_sites.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROME_BROWSER_HISTORY_TOP_SITES_H_ 5 #ifndef CHROME_BROWSER_HISTORY_TOP_SITES_H_
6 #define CHROME_BROWSER_HISTORY_TOP_SITES_H_ 6 #define CHROME_BROWSER_HISTORY_TOP_SITES_H_
7 #pragma once 7 #pragma once
8 8
9 #include <list> 9 #include <list>
10 #include <set> 10 #include <set>
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
77 // As this method may be invoked on any thread the ref count needs to be 77 // As this method may be invoked on any thread the ref count needs to be
78 // upped before this method returns, so this takes a scoped_refptr*. 78 // upped before this method returns, so this takes a scoped_refptr*.
79 bool GetPageThumbnail(const GURL& url, 79 bool GetPageThumbnail(const GURL& url,
80 scoped_refptr<RefCountedBytes>* bytes); 80 scoped_refptr<RefCountedBytes>* bytes);
81 81
82 // Get a thumbnail score for a given page. Returns true iff we have the 82 // Get a thumbnail score for a given page. Returns true iff we have the
83 // thumbnail score. This may be invoked on any thread. The score will 83 // thumbnail score. This may be invoked on any thread. The score will
84 // be copied to |score|. 84 // be copied to |score|.
85 virtual bool GetPageThumbnailScore(const GURL& url, ThumbnailScore* score); 85 virtual bool GetPageThumbnailScore(const GURL& url, ThumbnailScore* score);
86 86
87 // Get a temporary thumbnail score for a given page. Returns true iff we
88 // have the thumbnail score. Useful when checking if we should update a
89 // thumbnail for a given page. The score will be copied to |score|.
90 bool GetTemporaryPageThumbnailScore(const GURL& url, ThumbnailScore* score);
91
87 // Invoked from History if migration is needed. If this is invoked it will 92 // Invoked from History if migration is needed. If this is invoked it will
88 // be before HistoryLoaded is invoked. 93 // be before HistoryLoaded is invoked.
89 void MigrateFromHistory(); 94 void MigrateFromHistory();
90 95
91 // Invoked with data from migrating thumbnails out of history. 96 // Invoked with data from migrating thumbnails out of history.
92 void FinishHistoryMigration(const ThumbnailMigration& data); 97 void FinishHistoryMigration(const ThumbnailMigration& data);
93 98
94 // Invoked from history when it finishes loading. If MigrateFromHistory was 99 // Invoked from history when it finishes loading. If MigrateFromHistory was
95 // not invoked at this point then we load from the top sites service. 100 // not invoked at this point then we load from the top sites service.
96 void HistoryLoaded(); 101 void HistoryLoaded();
(...skipping 265 matching lines...) Expand 10 before | Expand all | Expand 10 after
362 367
363 // Are we loaded? 368 // Are we loaded?
364 bool loaded_; 369 bool loaded_;
365 370
366 DISALLOW_COPY_AND_ASSIGN(TopSites); 371 DISALLOW_COPY_AND_ASSIGN(TopSites);
367 }; 372 };
368 373
369 } // namespace history 374 } // namespace history
370 375
371 #endif // CHROME_BROWSER_HISTORY_TOP_SITES_H_ 376 #endif // CHROME_BROWSER_HISTORY_TOP_SITES_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/history/top_sites.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698