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

Unified Diff: chrome/service/cloud_print/printer_job_handler.cc

Issue 6523040: Added support to the Windows cloud print proxy to print XPS documents directl... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Code review changes Created 9 years, 10 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
« no previous file with comments | « chrome/service/cloud_print/print_system_win.cc ('k') | printing/backend/win_helper.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/service/cloud_print/printer_job_handler.cc
===================================================================
--- chrome/service/cloud_print/printer_job_handler.cc (revision 74874)
+++ chrome/service/cloud_print/printer_job_handler.cc (working copy)
@@ -109,7 +109,10 @@
request_->StartGetRequest(
CloudPrintHelpers::GetUrlForPrinterDelete(
cloud_print_server_url_, printer_info_cloud_.printer_id),
- this, auth_token_, kCloudPrintAPIMaxRetryCount);
+ this,
+ auth_token_,
+ kCloudPrintAPIMaxRetryCount,
+ std::string());
}
if (!task_in_progress_ && printer_update_pending_) {
printer_update_pending_ = false;
@@ -125,7 +128,10 @@
CloudPrintHelpers::GetUrlForJobFetch(
cloud_print_server_url_, printer_info_cloud_.printer_id,
job_fetch_reason_),
- this, auth_token_, kCloudPrintAPIMaxRetryCount);
+ this,
+ auth_token_,
+ kCloudPrintAPIMaxRetryCount,
+ std::string());
last_job_fetch_time_ = base::TimeTicks::Now();
VLOG(1) << "Last job fetch time for printer "
<< printer_info_.printer_name.c_str() << " is "
@@ -254,7 +260,12 @@
request_->StartPostRequest(
CloudPrintHelpers::GetUrlForPrinterUpdate(
cloud_print_server_url_, printer_info_cloud_.printer_id),
- this, auth_token_, kCloudPrintAPIMaxRetryCount, mime_type, post_data);
+ this,
+ auth_token_,
+ kCloudPrintAPIMaxRetryCount,
+ mime_type,
+ post_data,
+ std::string());
} else {
// We are done here. Go to the Stop state
MessageLoop::current()->PostTask(
@@ -408,7 +419,8 @@
request_->StartGetRequest(GURL(print_ticket_url.c_str()),
this,
auth_token_,
- kCloudPrintAPIMaxRetryCount);
+ kCloudPrintAPIMaxRetryCount,
+ std::string());
}
}
}
@@ -429,10 +441,13 @@
job_details_.print_ticket_ = data;
SetNextDataHandler(&PrinterJobHandler::HandlePrintDataResponse);
request_ = new CloudPrintURLFetcher;
+ std::string accept_headers = "Accept: ";
+ accept_headers += print_system_->GetSupportedMimeTypes();
request_->StartGetRequest(GURL(print_data_url_.c_str()),
this,
auth_token_,
- kJobDataMaxRetryCount);
+ kJobDataMaxRetryCount,
+ accept_headers);
} else {
// The print ticket was not valid. We are done here.
FailedFetchingJobData();
@@ -580,7 +595,8 @@
status),
this,
auth_token_,
- kCloudPrintAPIMaxRetryCount);
+ kCloudPrintAPIMaxRetryCount,
+ std::string());
}
}
}
« no previous file with comments | « chrome/service/cloud_print/print_system_win.cc ('k') | printing/backend/win_helper.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698