| OLD | NEW |
| 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_PRINTING_MESSAGE_FILTER_H_ | 5 #ifndef CHROME_BROWSER_PRINTING_PRINTING_MESSAGE_FILTER_H_ |
| 6 #define CHROME_BROWSER_PRINTING_PRINTING_MESSAGE_FILTER_H_ | 6 #define CHROME_BROWSER_PRINTING_PRINTING_MESSAGE_FILTER_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 15 matching lines...) Expand all Loading... |
| 26 } | 26 } |
| 27 | 27 |
| 28 // This class filters out incoming printing related IPC messages for the | 28 // This class filters out incoming printing related IPC messages for the |
| 29 // renderer process on the IPC thread. | 29 // renderer process on the IPC thread. |
| 30 class PrintingMessageFilter : public BrowserMessageFilter { | 30 class PrintingMessageFilter : public BrowserMessageFilter { |
| 31 public: | 31 public: |
| 32 PrintingMessageFilter(); | 32 PrintingMessageFilter(); |
| 33 | 33 |
| 34 // BrowserMessageFilter methods. | 34 // BrowserMessageFilter methods. |
| 35 virtual void OverrideThreadForMessage(const IPC::Message& message, | 35 virtual void OverrideThreadForMessage(const IPC::Message& message, |
| 36 BrowserThread::ID* thread); | 36 content::BrowserThread::ID* thread); |
| 37 virtual bool OnMessageReceived(const IPC::Message& message, | 37 virtual bool OnMessageReceived(const IPC::Message& message, |
| 38 bool* message_was_ok); | 38 bool* message_was_ok); |
| 39 | 39 |
| 40 private: | 40 private: |
| 41 virtual ~PrintingMessageFilter(); | 41 virtual ~PrintingMessageFilter(); |
| 42 | 42 |
| 43 #if defined(OS_WIN) | 43 #if defined(OS_WIN) |
| 44 // Used to pass resulting EMF from renderer to browser in printing. | 44 // Used to pass resulting EMF from renderer to browser in printing. |
| 45 void OnDuplicateSection(base::SharedMemoryHandle renderer_handle, | 45 void OnDuplicateSection(base::SharedMemoryHandle renderer_handle, |
| 46 base::SharedMemoryHandle* browser_handle); | 46 base::SharedMemoryHandle* browser_handle); |
| (...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 82 void OnCheckForCancel(const std::string& preview_ui_addr, | 82 void OnCheckForCancel(const std::string& preview_ui_addr, |
| 83 int preview_request_id, | 83 int preview_request_id, |
| 84 bool* cancel); | 84 bool* cancel); |
| 85 | 85 |
| 86 printing::PrintJobManager* print_job_manager_; | 86 printing::PrintJobManager* print_job_manager_; |
| 87 | 87 |
| 88 DISALLOW_COPY_AND_ASSIGN(PrintingMessageFilter); | 88 DISALLOW_COPY_AND_ASSIGN(PrintingMessageFilter); |
| 89 }; | 89 }; |
| 90 | 90 |
| 91 #endif // CHROME_BROWSER_PRINTING_PRINTING_MESSAGE_FILTER_H_ | 91 #endif // CHROME_BROWSER_PRINTING_PRINTING_MESSAGE_FILTER_H_ |
| OLD | NEW |