| Index: chrome/service/cloud_print/cloud_print_connector.cc
|
| diff --git a/chrome/service/cloud_print/cloud_print_connector.cc b/chrome/service/cloud_print/cloud_print_connector.cc
|
| index b9dd7409ce21d8c6b0bbf251ed89e96517edaadc..5bfd52554a872cd5acd93d7fe07687c6486cccd9 100644
|
| --- a/chrome/service/cloud_print/cloud_print_connector.cc
|
| +++ b/chrome/service/cloud_print/cloud_print_connector.cc
|
| @@ -24,15 +24,19 @@
|
| #include "chrome/grit/generated_resources.h"
|
| #include "chrome/service/cloud_print/cloud_print_service_helpers.h"
|
| #include "net/base/mime_util.h"
|
| +#include "net/traffic_annotation/network_traffic_annotation.h"
|
| #include "ui/base/l10n/l10n_util.h"
|
|
|
| namespace cloud_print {
|
|
|
| -CloudPrintConnector::CloudPrintConnector(Client* client,
|
| - const ConnectorSettings& settings)
|
| - : client_(client),
|
| - next_response_handler_(NULL),
|
| - stats_ptr_factory_(this) {
|
| +CloudPrintConnector::CloudPrintConnector(
|
| + Client* client,
|
| + const ConnectorSettings& settings,
|
| + const net::PartialNetworkTrafficAnnotationTag& partial_traffic_annotation)
|
| + : client_(client),
|
| + next_response_handler_(NULL),
|
| + partial_traffic_annotation_(partial_traffic_annotation),
|
| + stats_ptr_factory_(this) {
|
| settings_.CopyFrom(settings);
|
| }
|
|
|
| @@ -336,7 +340,7 @@ void CloudPrintConnector::StartGetRequest(const GURL& url,
|
| int max_retries,
|
| ResponseHandler handler) {
|
| next_response_handler_ = handler;
|
| - request_ = CloudPrintURLFetcher::Create();
|
| + request_ = CloudPrintURLFetcher::Create(partial_traffic_annotation_);
|
| request_->StartGetRequest(CloudPrintURLFetcher::REQUEST_UPDATE_JOB,
|
| url, this, max_retries, std::string());
|
| }
|
| @@ -349,7 +353,7 @@ void CloudPrintConnector::StartPostRequest(
|
| const std::string& post_data,
|
| ResponseHandler handler) {
|
| next_response_handler_ = handler;
|
| - request_ = CloudPrintURLFetcher::Create();
|
| + request_ = CloudPrintURLFetcher::Create(partial_traffic_annotation_);
|
| request_->StartPostRequest(
|
| type, url, this, max_retries, mime_type, post_data, std::string());
|
| }
|
| @@ -366,7 +370,8 @@ void CloudPrintConnector::ReportUserMessage(const std::string& message_id,
|
| net::AddMultipartFinalDelimiterForUpload(mime_boundary, &post_data);
|
| std::string mime_type("multipart/form-data; boundary=");
|
| mime_type += mime_boundary;
|
| - user_message_request_ = CloudPrintURLFetcher::Create();
|
| + user_message_request_ =
|
| + CloudPrintURLFetcher::Create(partial_traffic_annotation_);
|
| user_message_request_->StartPostRequest(
|
| CloudPrintURLFetcher::REQUEST_USER_MESSAGE, url, this, 1, mime_type,
|
| post_data, std::string());
|
|
|