2017-06-15 17:27:56 +02:00
|
|
|
diff --git chrome/browser/printing/print_job_worker.cc chrome/browser/printing/print_job_worker.cc
|
2021-11-10 22:57:31 +01:00
|
|
|
index 4b508191cf196..3c91214e09a69 100644
|
2017-06-15 17:27:56 +02:00
|
|
|
--- chrome/browser/printing/print_job_worker.cc
|
|
|
|
+++ chrome/browser/printing/print_job_worker.cc
|
2021-10-19 00:17:16 +02:00
|
|
|
@@ -148,6 +148,7 @@ PrintJobWorker::PrintJobWorker(int render_process_id, int render_frame_id)
|
2019-09-04 17:13:32 +02:00
|
|
|
PrintingContext::Create(printing_context_delegate_.get())),
|
|
|
|
thread_("Printing_Worker") {
|
2019-02-01 17:42:40 +01:00
|
|
|
DCHECK_CURRENTLY_ON(content::BrowserThread::IO);
|
2017-06-15 17:27:56 +02:00
|
|
|
+ printing_context_->set_render_ids(render_process_id, render_frame_id);
|
|
|
|
}
|
|
|
|
|
|
|
|
PrintJobWorker::~PrintJobWorker() {
|
|
|
|
diff --git printing/printing_context.h printing/printing_context.h
|
2021-10-19 00:17:16 +02:00
|
|
|
index b28af89c67f88..53f107bf413fa 100644
|
2017-06-15 17:27:56 +02:00
|
|
|
--- printing/printing_context.h
|
|
|
|
+++ printing/printing_context.h
|
2021-10-19 00:17:16 +02:00
|
|
|
@@ -143,6 +143,13 @@ class COMPONENT_EXPORT(PRINTING) PrintingContext {
|
2017-06-15 17:27:56 +02:00
|
|
|
|
|
|
|
int job_id() const { return job_id_; }
|
|
|
|
|
|
|
|
+ void set_render_ids(int render_process_id, int render_frame_id) {
|
|
|
|
+ render_process_id_ = render_process_id;
|
|
|
|
+ render_frame_id_ = render_frame_id;
|
|
|
|
+ }
|
|
|
|
+ int render_process_id() const { return render_process_id_; }
|
|
|
|
+ int render_frame_id() const { return render_frame_id_; }
|
|
|
|
+
|
|
|
|
protected:
|
|
|
|
explicit PrintingContext(Delegate* delegate);
|
|
|
|
|
2021-10-19 00:17:16 +02:00
|
|
|
@@ -170,6 +177,10 @@ class COMPONENT_EXPORT(PRINTING) PrintingContext {
|
2020-08-29 00:39:23 +02:00
|
|
|
|
2017-06-15 17:27:56 +02:00
|
|
|
// The job id for the current job. The value is 0 if no jobs are active.
|
|
|
|
int job_id_;
|
2020-08-29 00:39:23 +02:00
|
|
|
+
|
2017-06-15 17:27:56 +02:00
|
|
|
+ // Routing IDs for the frame that owns this object.
|
|
|
|
+ int render_process_id_ = 0;
|
|
|
|
+ int render_frame_id_ = 0;
|
|
|
|
};
|
2020-08-29 00:39:23 +02:00
|
|
|
|
|
|
|
} // namespace printing
|