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

Side by Side Diff: android_webview/browser/renderer_host/print_manager.h

Issue 822133003: Refactor webview to use //components/printing (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 11 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
OLDNEW
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 #ifndef ANDROID_WEBVIEW_BROWSER_RENDER_HOST_PRINT_MANAGER_H_ 5 #ifndef ANDROID_WEBVIEW_BROWSER_RENDER_HOST_PRINT_MANAGER_H_
6 #define ANDROID_WEBVIEW_BROWSER_RENDER_HOST_PRINT_MANAGER_H_ 6 #define ANDROID_WEBVIEW_BROWSER_RENDER_HOST_PRINT_MANAGER_H_
7 7
8 #include "base/callback_forward.h" 8 #include "base/callback_forward.h"
9 #include "base/threading/non_thread_safe.h" 9 #include "base/threading/non_thread_safe.h"
10 #include "content/public/browser/web_contents_observer.h" 10 #include "content/public/browser/web_contents_observer.h"
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
56 // already busy printing. 56 // already busy printing.
57 bool PrintNow(); 57 bool PrintNow();
58 58
59 private: 59 private:
60 virtual bool OnMessageReceived(const IPC::Message& message) override; 60 virtual bool OnMessageReceived(const IPC::Message& message) override;
61 void OnDidGetPrintedPagesCount(int cookie, int number_pages); 61 void OnDidGetPrintedPagesCount(int cookie, int number_pages);
62 void OnDidGetDocumentCookie(int cookie); 62 void OnDidGetDocumentCookie(int cookie);
63 void OnPrintingFailed(int cookie); 63 void OnPrintingFailed(int cookie);
64 void OnGetDefaultPrintSettingsReply(IPC::Message* reply_msg); 64 void OnGetDefaultPrintSettingsReply(IPC::Message* reply_msg);
65 void OnGetDefaultPrintSettings(IPC::Message* reply_msg); 65 void OnGetDefaultPrintSettings(IPC::Message* reply_msg);
66 void OnAllocateTempFileForPrinting(base::FileDescriptor* temp_file_fd, 66 void OnAllocateTempFileForPrinting(int render_view_id,
67 base::FileDescriptor* temp_file_fd,
67 int* sequence_number); 68 int* sequence_number);
68 void OnTempFileForPrintingWritten(int sequence_number); 69 void OnTempFileForPrintingWritten(int render_view_id, int sequence_number);
69 70
70 // Print Settings. 71 // Print Settings.
71 printing::PrintSettings* settings_; 72 printing::PrintSettings* settings_;
72 73
73 // File descriptor to export to. 74 // File descriptor to export to.
74 int fd_; 75 int fd_;
75 // Print manager delegate 76 // Print manager delegate
76 PrintManagerDelegate* delegate_; 77 PrintManagerDelegate* delegate_;
77 // Number of pages to print in the print job. 78 // Number of pages to print in the print job.
78 int number_pages_; 79 int number_pages_;
79 // The document cookie of the current PrinterQuery. 80 // The document cookie of the current PrinterQuery.
80 int cookie_; 81 int cookie_;
81 // Whether a print task is pending. 82 // Whether a print task is pending.
82 int printing_; 83 int printing_;
83 84
84 DISALLOW_COPY_AND_ASSIGN(PrintManager); 85 DISALLOW_COPY_AND_ASSIGN(PrintManager);
85 }; 86 };
86 87
87 } // namespace android_webview 88 } // namespace android_webview
88 89
89 #endif // ANDROID_WEBVIEW_BROWSER_RENDER_HOST_PRINT_MANAGER_H_ 90 #endif // ANDROID_WEBVIEW_BROWSER_RENDER_HOST_PRINT_MANAGER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698