diff options
author | Tom Sepez <tsepez@chromium.org> | 2016-01-29 17:05:08 -0800 |
---|---|---|
committer | Tom Sepez <tsepez@chromium.org> | 2016-01-29 17:05:08 -0800 |
commit | e5fbd7a170257b455f6ea8c94f71e827e6c3bb8d (patch) | |
tree | 1e5410c5f11b2d073cae51868aeb018e2a5c0ef0 /samples | |
parent | fe351dbc18e419b0ed9fbe34f2d1fb155b4f7bf1 (diff) | |
download | pdfium-e5fbd7a170257b455f6ea8c94f71e827e6c3bb8d.tar.xz |
Merge to XFA: Fix botched "CC:" parameter passing in JS_DocmailForm().
Original Review URL: https://codereview.chromium.org/1645413002 .
(cherry picked from commit 6902db5cbaf0afb8f2cb4df325e1a4e7d6acd53f)
TBR=thestig@chromium.org
Review URL: https://codereview.chromium.org/1648793006 .
Diffstat (limited to 'samples')
-rw-r--r-- | samples/pdfium_test.cc | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/samples/pdfium_test.cc b/samples/pdfium_test.cc index 8c0a249f30..e3e28a5034 100644 --- a/samples/pdfium_test.cc +++ b/samples/pdfium_test.cc @@ -211,6 +211,21 @@ void ExampleDocGotoPage(IPDF_JSPLATFORM*, int pageNumber) { printf("Goto Page: %d\n", pageNumber); } +void ExampleDocMail(IPDF_JSPLATFORM*, + void* mailData, + int length, + FPDF_BOOL bUI, + FPDF_WIDESTRING To, + FPDF_WIDESTRING Subject, + FPDF_WIDESTRING CC, + FPDF_WIDESTRING BCC, + FPDF_WIDESTRING Msg) { + printf("Mail Msg: %d, to=%ls, cc=%ls, bcc=%ls, subject=%ls, body=%ls\n", bUI, + GetPlatformWString(To).c_str(), GetPlatformWString(CC).c_str(), + GetPlatformWString(BCC).c_str(), GetPlatformWString(Subject).c_str(), + GetPlatformWString(Msg).c_str()); +} + void ExampleUnsupportedHandler(UNSUPPORT_INFO*, int type) { std::string feature = "Unknown"; switch (type) { @@ -411,6 +426,7 @@ void RenderPdf(const std::string& name, const char* pBuf, size_t len, platform_callbacks.version = 3; platform_callbacks.app_alert = ExampleAppAlert; platform_callbacks.Doc_gotoPage = ExampleDocGotoPage; + platform_callbacks.Doc_mail = ExampleDocMail; FPDF_FORMFILLINFO form_callbacks; memset(&form_callbacks, '\0', sizeof(form_callbacks)); |