X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;ds=sidebyside;f=src%2Fchrome%2Fbrowser%2Fbrowser_process_impl.cc;h=681515ce6bea1f2bbec47775e1ba021223e25f4d;hb=ff3e2503a20db9193d323c1d19c38c68004dec4a;hp=ac6f1c42aecd9a0cf46c996b2a8e8c68a9efd79e;hpb=7338fba38ba696536d1cc9d389afd716a6ab2fe6;p=platform%2Fframework%2Fweb%2Fcrosswalk.git diff --git a/src/chrome/browser/browser_process_impl.cc b/src/chrome/browser/browser_process_impl.cc index ac6f1c4..681515c 100644 --- a/src/chrome/browser/browser_process_impl.cc +++ b/src/chrome/browser/browser_process_impl.cc @@ -64,8 +64,6 @@ #include "chrome/browser/safe_browsing/safe_browsing_service.h" #include "chrome/browser/shell_integration.h" #include "chrome/browser/status_icons/status_tray.h" -#include "chrome/browser/storage_monitor/storage_monitor.h" -#include "chrome/browser/thumbnails/render_widget_snapshot_taker.h" #include "chrome/browser/ui/bookmarks/bookmark_prompt_controller.h" #include "chrome/browser/ui/browser_dialogs.h" #include "chrome/browser/ui/browser_finder.h" @@ -81,6 +79,7 @@ #include "chrome/common/url_constants.h" #include "chrome/installer/util/google_update_constants.h" #include "components/policy/core/common/policy_service.h" +#include "components/translate/core/browser/translate_download_manager.h" #include "content/public/browser/browser_thread.h" #include "content/public/browser/child_process_security_policy.h" #include "content/public/browser/notification_details.h" @@ -112,6 +111,7 @@ #if !defined(OS_ANDROID) && !defined(OS_IOS) #include "chrome/browser/media_galleries/media_file_system_registry.h" +#include "components/storage_monitor/storage_monitor.h" #endif #if defined(ENABLE_PLUGIN_INSTALLATION) @@ -161,9 +161,6 @@ BrowserProcessImpl::BrowserProcessImpl( created_safe_browsing_service_(false), module_ref_count_(0), did_start_(false), - checked_for_new_frames_(false), - using_new_frames_(false), - render_widget_snapshot_taker_(new RenderWidgetSnapshotTaker), download_status_updater_(new DownloadStatusUpdater), local_state_task_runner_(local_state_task_runner) { g_browser_process = this; @@ -266,11 +263,11 @@ void BrowserProcessImpl::StartTearDown() { #if !defined(OS_ANDROID) && !defined(OS_IOS) media_file_system_registry_.reset(); - // Delete |storage_monitor_| now. Otherwise the FILE thread would be gone - // when we try to release it in the dtor and Valgrind would report a - // leak on almost every single browser_test. + // Remove the global instance of the Storage Monitor now. Otherwise the + // FILE thread would be gone when we try to release it in the dtor and + // Valgrind would report a leak on almost every single browser_test. // TODO(gbillock): Make this unnecessary. - storage_monitor_.reset(); + StorageMonitor::Destroy(); #endif message_center::MessageCenter::Shutdown(); @@ -552,10 +549,6 @@ GpuModeManager* BrowserProcessImpl::gpu_mode_manager() { return gpu_mode_manager_.get(); } -RenderWidgetSnapshotTaker* BrowserProcessImpl::GetRenderWidgetSnapshotTaker() { - return render_widget_snapshot_taker_.get(); -} - AutomationProviderList* BrowserProcessImpl::GetAutomationProviderList() { DCHECK(CalledOnValidThread()); #if defined(ENABLE_AUTOMATION) @@ -636,6 +629,7 @@ void BrowserProcessImpl::SetApplicationLocale(const std::string& locale) { locale_ = locale; extension_l10n_util::SetProcessLocale(locale); chrome::ChromeContentBrowserClient::SetApplicationLocale(locale); + TranslateDownloadManager::GetInstance()->set_application_locale(locale); } DownloadStatusUpdater* BrowserProcessImpl::download_status_updater() { @@ -650,21 +644,6 @@ BookmarkPromptController* BrowserProcessImpl::bookmark_prompt_controller() { #endif } -StorageMonitor* BrowserProcessImpl::storage_monitor() { -#if defined(OS_ANDROID) || defined(OS_IOS) - return NULL; -#else - return storage_monitor_.get(); -#endif -} - -void BrowserProcessImpl::set_storage_monitor_for_test( - scoped_ptr monitor) { -#if !defined(OS_ANDROID) && !defined(OS_IOS) - storage_monitor_ = monitor.Pass(); -#endif -} - MediaFileSystemRegistry* BrowserProcessImpl::media_file_system_registry() { #if defined(OS_ANDROID) || defined(OS_IOS) return NULL; @@ -976,7 +955,7 @@ void BrowserProcessImpl::PreMainMessageLoopRun() { #endif #if !defined(OS_ANDROID) && !defined(OS_IOS) - storage_monitor_.reset(StorageMonitor::Create()); + StorageMonitor::Create(); #endif platform_part_->PreMainMessageLoopRun();