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

Unified Diff: chrome/browser/webdata/web_data_service.h

Issue 10021008: Reland r131019: Move most TemplateURL data members to a new struct, TemplateURLData. This allows us… (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/webdata/keyword_table_unittest.cc ('k') | chrome/browser/webdata/web_data_service.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/webdata/web_data_service.h
===================================================================
--- chrome/browser/webdata/web_data_service.h (revision 131175)
+++ chrome/browser/webdata/web_data_service.h (working copy)
@@ -20,6 +20,7 @@
#include "base/message_loop_helpers.h"
#include "base/memory/ref_counted.h"
#include "base/synchronization/lock.h"
+#include "chrome/browser/search_engines/template_url.h"
#include "chrome/browser/search_engines/template_url_id.h"
#include "chrome/browser/webdata/keyword_table.h"
#include "content/public/browser/browser_thread.h"
@@ -38,7 +39,6 @@
class MessageLoop;
class Profile;
class SkBitmap;
-class TemplateURL;
class WebDatabase;
namespace base {
@@ -119,8 +119,9 @@
int64 default_search_provider_id;
// Version of the built-in keywords. A value of 0 indicates a first run.
int builtin_keyword_version;
- // Backup of the default search provider. NULL if the backup is invalid.
- TemplateURL* default_search_provider_backup;
+ // Backup of the default search provider, and whether the backup is valid.
+ bool backup_valid;
+ TemplateURLData default_search_provider_backup;
// Indicates if default search provider has been changed by something
// other than user's action in the browser.
bool did_default_search_provider_change;
@@ -335,10 +336,9 @@
// Many of the keyword related methods do not return a handle. This is because
// the caller (TemplateURLService) does not need to know when the request is
// done.
+
void AddKeyword(const TemplateURL& url);
-
- void RemoveKeyword(const TemplateURL& url);
-
+ void RemoveKeyword(TemplateURLID id);
void UpdateKeyword(const TemplateURL& url);
// Fetches the keywords.
@@ -599,7 +599,7 @@
content::BrowserThread::UI>;
friend class base::DeleteHelper<WebDataService>;
- typedef GenericRequest2<std::vector<const TemplateURL*>,
+ typedef GenericRequest2<std::vector<const TemplateURLData*>,
KeywordTable::Keywords> SetKeywordsRequest;
// Invoked on the main thread if initializing the db fails.
« no previous file with comments | « chrome/browser/webdata/keyword_table_unittest.cc ('k') | chrome/browser/webdata/web_data_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698