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

Unified Diff: chrome/browser/spellchecker/spellcheck_service.cc

Issue 1864583006: Simplify BrowserContext by removing redundant methods. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix Created 4 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
Index: chrome/browser/spellchecker/spellcheck_service.cc
diff --git a/chrome/browser/spellchecker/spellcheck_service.cc b/chrome/browser/spellchecker/spellcheck_service.cc
index dfc4898bf0f392e060ef8cf83840562013fdd328..180823d8d90bd25f7740319e659be315ef5c8c19 100644
--- a/chrome/browser/spellchecker/spellcheck_service.cc
+++ b/chrome/browser/spellchecker/spellcheck_service.cc
@@ -29,6 +29,7 @@
#include "content/public/browser/notification_service.h"
#include "content/public/browser/notification_types.h"
#include "content/public/browser/render_process_host.h"
+#include "content/public/browser/storage_partition.h"
#include "ipc/ipc_platform_file.h"
using content::BrowserThread;
@@ -87,7 +88,9 @@ SpellcheckService::SpellcheckService(content::BrowserContext* context)
&language_code,
&country_code);
feedback_sender_.reset(new spellcheck::FeedbackSender(
- context->GetRequestContext(), language_code, country_code));
+ content::BrowserContext::GetDefaultStoragePartition(context)->
+ GetURLRequestContext(),
+ language_code, country_code));
pref_change_registrar_.Add(
prefs::kSpellCheckDictionaries,
@@ -226,7 +229,10 @@ void SpellcheckService::LoadHunspellDictionaries() {
std::string dictionary;
dictionary_value->GetAsString(&dictionary);
hunspell_dictionaries_.push_back(new SpellcheckHunspellDictionary(
- dictionary, context_->GetRequestContext(), this));
+ dictionary,
+ content::BrowserContext::GetDefaultStoragePartition(context_)->
+ GetURLRequestContext(),
+ this));
hunspell_dictionaries_.back()->AddObserver(this);
hunspell_dictionaries_.back()->Load();
}
« no previous file with comments | « chrome/browser/search_engines/template_url_fetcher_factory.cc ('k') | chrome/browser/spellchecker/spelling_service_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698