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

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

Issue 9071014: Database usage adjustment for .../history (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Simplify SQL Created 8 years, 11 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 | « chrome/browser/history/text_database.cc ('k') | chrome/browser/history/thumbnail_database.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_THUMBNAIL_DATABASE_H_ 5 #ifndef CHROME_BROWSER_HISTORY_THUMBNAIL_DATABASE_H_
6 #define CHROME_BROWSER_HISTORY_THUMBNAIL_DATABASE_H_ 6 #define CHROME_BROWSER_HISTORY_THUMBNAIL_DATABASE_H_
7 #pragma once 7 #pragma once
8 8
9 #include <vector> 9 #include <vector>
10 10
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
68 68
69 // Vacuums the database. This will cause sqlite to defragment and collect 69 // Vacuums the database. This will cause sqlite to defragment and collect
70 // unused space in the file. It can be VERY SLOW. 70 // unused space in the file. It can be VERY SLOW.
71 void Vacuum(); 71 void Vacuum();
72 72
73 // Thumbnails ---------------------------------------------------------------- 73 // Thumbnails ----------------------------------------------------------------
74 74
75 // Sets the given data to be the thumbnail for the given URL, 75 // Sets the given data to be the thumbnail for the given URL,
76 // overwriting any previous data. If the SkBitmap contains no pixel 76 // overwriting any previous data. If the SkBitmap contains no pixel
77 // data, the thumbnail will be deleted. 77 // data, the thumbnail will be deleted.
78 void SetPageThumbnail(const GURL& url, 78 bool SetPageThumbnail(const GURL& url,
79 URLID id, 79 URLID id,
80 const gfx::Image* thumbnail, 80 const gfx::Image* thumbnail,
81 const ThumbnailScore& score, 81 const ThumbnailScore& score,
82 base::Time time); 82 base::Time time);
83 83
84 // Retrieves thumbnail data for the given URL, returning true on success, 84 // Retrieves thumbnail data for the given URL, returning true on success,
85 // false if there is no such thumbnail or there was some other error. 85 // false if there is no such thumbnail or there was some other error.
86 bool GetPageThumbnail(URLID id, std::vector<unsigned char>* data); 86 bool GetPageThumbnail(URLID id, std::vector<unsigned char>* data);
87 87
88 // Delete the thumbnail with the provided id. Returns false on failure 88 // Delete the thumbnail with the provided id. Returns false on failure
(...skipping 211 matching lines...) Expand 10 before | Expand all | Expand 10 after
300 const HistoryPublisher* history_publisher_; 300 const HistoryPublisher* history_publisher_;
301 301
302 // True if migration to TopSites has been done and the thumbnails 302 // True if migration to TopSites has been done and the thumbnails
303 // table should not be used. 303 // table should not be used.
304 bool use_top_sites_; 304 bool use_top_sites_;
305 }; 305 };
306 306
307 } // namespace history 307 } // namespace history
308 308
309 #endif // CHROME_BROWSER_HISTORY_THUMBNAIL_DATABASE_H_ 309 #endif // CHROME_BROWSER_HISTORY_THUMBNAIL_DATABASE_H_
OLDNEW
« no previous file with comments | « chrome/browser/history/text_database.cc ('k') | chrome/browser/history/thumbnail_database.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698