summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--base/task.h29
-rw-r--r--chrome/browser/search_engines/search_host_to_urls_map_unittest.cc4
-rw-r--r--chrome/browser/search_engines/search_provider_install_state_dispatcher_host.h4
-rw-r--r--chrome/browser/search_engines/template_url_prepopulate_data.cc4
4 files changed, 22 insertions, 19 deletions
diff --git a/base/task.h b/base/task.h
index 34b3009..e6ac33c 100644
--- a/base/task.h
+++ b/base/task.h
@@ -107,30 +107,30 @@ class ScopedRunnableMethodFactory {
template <class Method, class A, class B, class C>
inline CancelableTask* NewRunnableMethod(Method method,
- const A& a,
- const B& b,
- const C& c) {
+ const A& a,
+ const B& b,
+ const C& c) {
return new RunnableMethod<Method, Tuple3<A, B, C> >(
weak_factory_.GetWeakPtr(), method, MakeTuple(a, b, c));
}
template <class Method, class A, class B, class C, class D>
inline CancelableTask* NewRunnableMethod(Method method,
- const A& a,
- const B& b,
- const C& c,
- const D& d) {
+ const A& a,
+ const B& b,
+ const C& c,
+ const D& d) {
return new RunnableMethod<Method, Tuple4<A, B, C, D> >(
weak_factory_.GetWeakPtr(), method, MakeTuple(a, b, c, d));
}
template <class Method, class A, class B, class C, class D, class E>
inline CancelableTask* NewRunnableMethod(Method method,
- const A& a,
- const B& b,
- const C& c,
- const D& d,
- const E& e) {
+ const A& a,
+ const B& b,
+ const C& c,
+ const D& d,
+ const E& e) {
return new RunnableMethod<Method, Tuple5<A, B, C, D, E> >(
weak_factory_.GetWeakPtr(), method, MakeTuple(a, b, c, d, e));
}
@@ -143,7 +143,8 @@ class ScopedRunnableMethodFactory {
template <class Method, class Params>
class RunnableMethod : public CancelableTask {
public:
- RunnableMethod(const base::WeakPtr<T>& obj, Method meth,
+ RunnableMethod(const base::WeakPtr<T>& obj,
+ Method meth,
const Params& params)
: obj_(obj),
meth_(meth),
@@ -187,6 +188,7 @@ class DeleteTask : public CancelableTask {
virtual void Cancel() {
obj_ = NULL;
}
+
private:
T* obj_;
};
@@ -204,6 +206,7 @@ class ReleaseTask : public CancelableTask {
virtual void Cancel() {
obj_ = NULL;
}
+
private:
T* obj_;
};
diff --git a/chrome/browser/search_engines/search_host_to_urls_map_unittest.cc b/chrome/browser/search_engines/search_host_to_urls_map_unittest.cc
index 6602c25..cdb4925 100644
--- a/chrome/browser/search_engines/search_host_to_urls_map_unittest.cc
+++ b/chrome/browser/search_engines/search_host_to_urls_map_unittest.cc
@@ -26,10 +26,6 @@ class SearchHostToURLsMapTest : public testing::Test {
TemplateURLRef::SetGoogleBaseURL(new std::string(base_url));
}
- void VerifyDefault(const std::string& origin) {
- ASSERT_STREQ(origin.c_str(), provider_map_->default_search_origin_.c_str());
- }
-
scoped_ptr<SearchHostToURLsMap> provider_map_;
TemplateURL t_urls_[2];
std::string host_;
diff --git a/chrome/browser/search_engines/search_provider_install_state_dispatcher_host.h b/chrome/browser/search_engines/search_provider_install_state_dispatcher_host.h
index d7de57f..96ca00e 100644
--- a/chrome/browser/search_engines/search_provider_install_state_dispatcher_host.h
+++ b/chrome/browser/search_engines/search_provider_install_state_dispatcher_host.h
@@ -47,7 +47,11 @@ class SearchProviderInstallStateDispatcherHost {
IPC::Message* reply_msg,
ViewHostMsg_GetSearchProviderInstallState_Params install_state);
+ // Used to reply to messages.
ResourceMessageFilter* ipc_sender_;
+
+ // Copied from the profile since the profile can't be accessed on the I/O
+ // thread.
const bool is_off_the_record_;
DISALLOW_COPY_AND_ASSIGN(SearchProviderInstallStateDispatcherHost);
diff --git a/chrome/browser/search_engines/template_url_prepopulate_data.cc b/chrome/browser/search_engines/template_url_prepopulate_data.cc
index f66735d..c542ddd 100644
--- a/chrome/browser/search_engines/template_url_prepopulate_data.cc
+++ b/chrome/browser/search_engines/template_url_prepopulate_data.cc
@@ -3183,7 +3183,7 @@ TemplateURL* MakePrepopulatedTemplateURL(const wchar_t* name,
return new_turl;
}
-void GetPrepopulatedTemplatefromPrefs(PrefService* prefs,
+void GetPrepopulatedTemplateFromPrefs(PrefService* prefs,
std::vector<TemplateURL*>* t_urls) {
const ListValue* list =
prefs->GetList(prefs::kSearchProviderOverrides);
@@ -3243,7 +3243,7 @@ void GetPrepopulatedEngines(PrefService* prefs,
// If there is a set of search engines in the preferences file, it overrides
// the built-in set.
*default_search_provider_index = 0;
- GetPrepopulatedTemplatefromPrefs(prefs, t_urls);
+ GetPrepopulatedTemplateFromPrefs(prefs, t_urls);
if (!t_urls->empty())
return;