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

Side by Side Diff: chrome/browser/printing/print_job_worker.h

Issue 7064033: Virtual destructors should have virtual keyword. (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Created 9 years, 7 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROME_BROWSER_PRINTING_PRINT_JOB_WORKER_H__ 5 #ifndef CHROME_BROWSER_PRINTING_PRINT_JOB_WORKER_H__
6 #define CHROME_BROWSER_PRINTING_PRINT_JOB_WORKER_H__ 6 #define CHROME_BROWSER_PRINTING_PRINT_JOB_WORKER_H__
7 #pragma once 7 #pragma once
8 8
9 #include "base/memory/ref_counted.h" 9 #include "base/memory/ref_counted.h"
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
(...skipping 14 matching lines...) Expand all
25 25
26 // Worker thread code. All this code, except for the constructor, is executed in 26 // Worker thread code. All this code, except for the constructor, is executed in
27 // the worker thread. It manages the PrintingContext, which can be blocking 27 // the worker thread. It manages the PrintingContext, which can be blocking
28 // and/or run a message loop. This is the object that generates most 28 // and/or run a message loop. This is the object that generates most
29 // NOTIFY_PRINT_JOB_EVENT notifications, but they are generated through a 29 // NOTIFY_PRINT_JOB_EVENT notifications, but they are generated through a
30 // NotificationTask task to be executed from the right thread, the UI thread. 30 // NotificationTask task to be executed from the right thread, the UI thread.
31 // PrintJob always outlives its worker instance. 31 // PrintJob always outlives its worker instance.
32 class PrintJobWorker : public base::Thread { 32 class PrintJobWorker : public base::Thread {
33 public: 33 public:
34 explicit PrintJobWorker(PrintJobWorkerOwner* owner); 34 explicit PrintJobWorker(PrintJobWorkerOwner* owner);
35 ~PrintJobWorker(); 35 virtual ~PrintJobWorker();
36 36
37 void SetNewOwner(PrintJobWorkerOwner* new_owner); 37 void SetNewOwner(PrintJobWorkerOwner* new_owner);
38 38
39 // Initializes the print settings. If |ask_user_for_settings| is true, a 39 // Initializes the print settings. If |ask_user_for_settings| is true, a
40 // Print... dialog box will be shown to ask the user his preference. 40 // Print... dialog box will be shown to ask the user his preference.
41 void GetSettings(bool ask_user_for_settings, 41 void GetSettings(bool ask_user_for_settings,
42 gfx::NativeView parent_view, 42 gfx::NativeView parent_view,
43 int document_page_count, 43 int document_page_count,
44 bool has_selection, 44 bool has_selection,
45 bool use_overlays); 45 bool use_overlays);
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after
130 130
131 template <> 131 template <>
132 struct RunnableMethodTraits<printing::PrintJobWorker> { 132 struct RunnableMethodTraits<printing::PrintJobWorker> {
133 void RetainCallee(printing::PrintJobWorker* obj); 133 void RetainCallee(printing::PrintJobWorker* obj);
134 void ReleaseCallee(printing::PrintJobWorker* obj); 134 void ReleaseCallee(printing::PrintJobWorker* obj);
135 private: 135 private:
136 scoped_refptr<printing::PrintJobWorkerOwner> owner_; 136 scoped_refptr<printing::PrintJobWorkerOwner> owner_;
137 }; 137 };
138 138
139 #endif // CHROME_BROWSER_PRINTING_PRINT_JOB_WORKER_H__ 139 #endif // CHROME_BROWSER_PRINTING_PRINT_JOB_WORKER_H__
OLDNEW
« no previous file with comments | « chrome/browser/printing/print_job_manager.h ('k') | chrome/browser/profiles/off_the_record_profile_io_data.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698