OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 #include "android_webview/browser/renderer_host/print_manager.h" | 5 #include "android_webview/browser/renderer_host/print_manager.h" |
6 | 6 |
7 #include "android_webview/browser/aw_browser_context.h" | 7 #include "android_webview/browser/aw_browser_context.h" |
8 #include "android_webview/common/print_messages.h" | 8 #include "android_webview/common/print_messages.h" |
9 #include "android_webview/common/render_view_messages.h" | 9 #include "android_webview/common/render_view_messages.h" |
10 #include "base/android/scoped_java_ref.h" | 10 #include "base/android/scoped_java_ref.h" |
11 #include "base/callback.h" | 11 #include "base/callback.h" |
12 #include "base/files/file_util.h" | 12 #include "base/file_util.h" |
13 #include "base/logging.h" | 13 #include "base/logging.h" |
14 #include "content/public/browser/browser_thread.h" | 14 #include "content/public/browser/browser_thread.h" |
15 #include "printing/print_settings.h" | 15 #include "printing/print_settings.h" |
16 | 16 |
17 using content::BrowserThread; | 17 using content::BrowserThread; |
18 using printing::PrintSettings; | 18 using printing::PrintSettings; |
19 | 19 |
20 namespace android_webview { | 20 namespace android_webview { |
21 | 21 |
22 PrintManager::PrintManager(content::WebContents* contents, | 22 PrintManager::PrintManager(content::WebContents* contents, |
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
134 bool PrintManager::PrintNow() { | 134 bool PrintManager::PrintNow() { |
135 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); | 135 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); |
136 if (printing_) | 136 if (printing_) |
137 return false; | 137 return false; |
138 | 138 |
139 printing_ = true; | 139 printing_ = true; |
140 return Send(new PrintMsg_PrintPages(routing_id())); | 140 return Send(new PrintMsg_PrintPages(routing_id())); |
141 } | 141 } |
142 | 142 |
143 } // namespace android_webview | 143 } // namespace android_webview |
OLD | NEW |