2017-06-15 08:27:56 -07:00
|
|
|
diff --git chrome/browser/printing/print_job_worker.cc chrome/browser/printing/print_job_worker.cc
|
2020-12-02 17:31:49 -05:00
|
|
|
index 8e648fa8d563..66a52ce51147 100644
|
2017-06-15 08:27:56 -07:00
|
|
|
--- chrome/browser/printing/print_job_worker.cc
|
|
|
|
+++ chrome/browser/printing/print_job_worker.cc
|
2020-10-08 15:54:42 -04:00
|
|
|
@@ -134,6 +134,7 @@ PrintJobWorker::PrintJobWorker(int render_process_id, int render_frame_id)
|
2019-09-04 15:13:32 +00:00
|
|
|
PrintingContext::Create(printing_context_delegate_.get())),
|
|
|
|
thread_("Printing_Worker") {
|
2019-02-01 16:42:40 +00:00
|
|
|
DCHECK_CURRENTLY_ON(content::BrowserThread::IO);
|
2017-06-15 08:27:56 -07:00
|
|
|
+ printing_context_->set_render_ids(render_process_id, render_frame_id);
|
|
|
|
}
|
|
|
|
|
|
|
|
PrintJobWorker::~PrintJobWorker() {
|
|
|
|
diff --git printing/printing_context.h printing/printing_context.h
|
2020-12-02 17:31:49 -05:00
|
|
|
index 896d1b26f492..59d17b49f0d3 100644
|
2017-06-15 08:27:56 -07:00
|
|
|
--- printing/printing_context.h
|
|
|
|
+++ printing/printing_context.h
|
2020-12-02 17:31:49 -05:00
|
|
|
@@ -134,6 +134,13 @@ class PRINTING_EXPORT PrintingContext {
|
2017-06-15 08:27:56 -07: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);
|
|
|
|
|
2020-12-02 17:31:49 -05:00
|
|
|
@@ -157,6 +164,10 @@ class PRINTING_EXPORT PrintingContext {
|
2020-08-28 18:39:23 -04:00
|
|
|
|
2017-06-15 08:27:56 -07:00
|
|
|
// The job id for the current job. The value is 0 if no jobs are active.
|
|
|
|
int job_id_;
|
2020-08-28 18:39:23 -04:00
|
|
|
+
|
2017-06-15 08:27:56 -07:00
|
|
|
+ // Routing IDs for the frame that owns this object.
|
|
|
|
+ int render_process_id_ = 0;
|
|
|
|
+ int render_frame_id_ = 0;
|
|
|
|
};
|
2020-08-28 18:39:23 -04:00
|
|
|
|
|
|
|
} // namespace printing
|