| Index: chrome/browser/profiles/profile_impl.cc
|
| diff --git a/chrome/browser/profiles/profile_impl.cc b/chrome/browser/profiles/profile_impl.cc
|
| index 11fd5c04e7418d9679dcfeace8ca733519ef4543..d694ae3d09490473b4a887f3daa41c1951a02d66 100644
|
| --- a/chrome/browser/profiles/profile_impl.cc
|
| +++ b/chrome/browser/profiles/profile_impl.cc
|
| @@ -67,6 +67,7 @@
|
| #include "chrome/browser/search_engines/template_url_service.h"
|
| #include "chrome/browser/sessions/session_service_factory.h"
|
| #include "chrome/browser/speech/chrome_speech_input_manager.h"
|
| +#include "chrome/browser/speech/chrome_speech_input_preferences.h"
|
| #include "chrome/browser/spellchecker/spellcheck_profile.h"
|
| #include "chrome/browser/sync/profile_sync_factory_impl.h"
|
| #include "chrome/browser/sync/profile_sync_service.h"
|
| @@ -494,9 +495,6 @@ void ProfileImpl::DoFinalInit() {
|
| GetSpellCheckProfile()->StartRecordingMetrics(
|
| GetPrefs()->GetBoolean(prefs::kEnableSpellCheck));
|
|
|
| - speech_input::ChromeSpeechInputManager::GetInstance()->set_censor_results(
|
| - prefs->GetBoolean(prefs::kSpeechInputCensorResults));
|
| -
|
| FilePath cookie_path = GetPath();
|
| cookie_path = cookie_path.Append(chrome::kCookieFilename);
|
| FilePath origin_bound_cert_path = GetPath();
|
| @@ -1158,12 +1156,20 @@ HostZoomMap* ProfileImpl::GetHostZoomMap() {
|
| }
|
|
|
| GeolocationPermissionContext* ProfileImpl::GetGeolocationPermissionContext() {
|
| - if (!geolocation_permission_context_.get())
|
| + if (!geolocation_permission_context_.get()) {
|
| geolocation_permission_context_ =
|
| new ChromeGeolocationPermissionContext(this);
|
| + }
|
| return geolocation_permission_context_.get();
|
| }
|
|
|
| +SpeechInputPreferences* ProfileImpl::GetSpeechInputPreferences() {
|
| + if (!speech_input_preferences_.get()) {
|
| + speech_input_preferences_ = new ChromeSpeechInputPreferences(GetPrefs());
|
| + }
|
| + return speech_input_preferences_.get();
|
| +}
|
| +
|
| UserStyleSheetWatcher* ProfileImpl::GetUserStyleSheetWatcher() {
|
| if (!user_style_sheet_watcher_.get()) {
|
| user_style_sheet_watcher_ = new UserStyleSheetWatcher(GetPath());
|
| @@ -1561,9 +1567,8 @@ void ProfileImpl::Observe(int type,
|
| process->Send(new SpellCheckMsg_EnableAutoSpellCorrect(enabled));
|
| }
|
| } else if (*pref_name_in == prefs::kSpeechInputCensorResults) {
|
| - speech_input::ChromeSpeechInputManager::GetInstance()->
|
| - set_censor_results(prefs->GetBoolean(
|
| - prefs::kSpeechInputCensorResults));
|
| + GetSpeechInputPreferences()->set_censor_results(prefs->GetBoolean(
|
| + prefs::kSpeechInputCensorResults));
|
| } else if (*pref_name_in == prefs::kClearSiteDataOnExit) {
|
| clear_local_state_on_exit_ =
|
| prefs->GetBoolean(prefs::kClearSiteDataOnExit);
|
|
|