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

Unified Diff: chrome/browser/profiles/profile_impl_io_data.cc

Issue 2354323002: Propagate network delegate events to ChromeDataUseAscriber. (Closed)
Patch Set: Added comments Created 4 years, 3 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/profiles/profile_impl_io_data.cc
diff --git a/chrome/browser/profiles/profile_impl_io_data.cc b/chrome/browser/profiles/profile_impl_io_data.cc
index 09bb042f8c3eea9c150e6b07806631f206c67738..68d0c685a016abec63ce9c9ec7d88c189dd1333d 100644
--- a/chrome/browser/profiles/profile_impl_io_data.cc
+++ b/chrome/browser/profiles/profile_impl_io_data.cc
@@ -25,6 +25,7 @@
#include "chrome/browser/chrome_notification_types.h"
#include "chrome/browser/custom_handlers/protocol_handler_registry.h"
#include "chrome/browser/custom_handlers/protocol_handler_registry_factory.h"
+#include "chrome/browser/data_use_measurement/chrome_data_use_ascriber.h"
#include "chrome/browser/io_thread.h"
#include "chrome/browser/net/chrome_network_delegate.h"
#include "chrome/browser/net/http_server_properties_manager_factory.h"
@@ -45,6 +46,7 @@
#include "components/data_reduction_proxy/core/browser/data_reduction_proxy_io_data.h"
#include "components/data_reduction_proxy/core/browser/data_reduction_proxy_settings.h"
#include "components/data_reduction_proxy/core/browser/data_store_impl.h"
+#include "components/data_use_measurement/core/data_use_network_delegate.h"
#include "components/domain_reliability/monitor.h"
#include "components/net_log/chrome_net_log.h"
#include "components/prefs/json_pref_store.h"
@@ -477,7 +479,10 @@ void ProfileImplIOData::InitializeInternal(
main_context->set_net_log(io_thread->net_log());
network_delegate_ = data_reduction_proxy_io_data()->CreateNetworkDelegate(
- std::move(chrome_network_delegate), true);
+ base::MakeUnique<data_use_measurement::DataUseNetworkDelegate>(
+ std::move(chrome_network_delegate),
+ io_thread_globals->data_use_ascriber.get()),
+ true);
main_context->set_network_delegate(network_delegate_.get());

Powered by Google App Engine
This is Rietveld 408576698