summaryrefslogtreecommitdiffstats
path: root/chrome/browser/printing/print_job_worker.cc
diff options
context:
space:
mode:
Diffstat (limited to 'chrome/browser/printing/print_job_worker.cc')
-rw-r--r--chrome/browser/printing/print_job_worker.cc6
1 files changed, 5 insertions, 1 deletions
diff --git a/chrome/browser/printing/print_job_worker.cc b/chrome/browser/printing/print_job_worker.cc
index d8c2d83..caf5ad3 100644
--- a/chrome/browser/printing/print_job_worker.cc
+++ b/chrome/browser/printing/print_job_worker.cc
@@ -166,7 +166,11 @@ void PrintJobWorker::OnNewPage() {
// Is the page available?
scoped_refptr<PrintedPage> page;
if (!document_->GetPage(page_number_.ToInt(), &page)) {
- // The page is implicitly requested.
+ // We need to wait for the page to be available.
+ MessageLoop::current()->PostDelayedTask(
+ FROM_HERE,
+ NewRunnableMethod(this, &PrintJobWorker::OnNewPage),
+ 500);
break;
}
// The page is there, print it.