summaryrefslogtreecommitdiff
path: root/fpdfsdk/fpdfedit_embeddertest.cpp
diff options
context:
space:
mode:
authorNicolas Pena <npm@chromium.org>2017-04-13 15:28:20 -0400
committerChromium commit bot <commit-bot@chromium.org>2017-04-13 19:52:31 +0000
commit742977f943b30638427d1ef6532acbc3d1c36bff (patch)
treeaa6d3fccc2479002ddf2550bc6d25c14d7567737 /fpdfsdk/fpdfedit_embeddertest.cpp
parenta119340ec92412d07e60654b2b22a5a5bea979b0 (diff)
downloadpdfium-742977f943b30638427d1ef6532acbc3d1c36bff.tar.xz
Add embeddertest for form text rendering and saving
This CL adds an embeddertest that adds text to a textfield and saves it. It also adds a new 'charcode' option for .evt files in pdfium_test. Change-Id: I14fbf50e2b1d5ae0bdc68d1dd25dc4f889c49bfb Reviewed-on: https://pdfium-review.googlesource.com/4150 Commit-Queue: Nicolás Peña <npm@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org> Reviewed-by: Tom Sepez <tsepez@chromium.org> Reviewed-by: dsinclair <dsinclair@chromium.org>
Diffstat (limited to 'fpdfsdk/fpdfedit_embeddertest.cpp')
-rw-r--r--fpdfsdk/fpdfedit_embeddertest.cpp16
1 files changed, 0 insertions, 16 deletions
diff --git a/fpdfsdk/fpdfedit_embeddertest.cpp b/fpdfsdk/fpdfedit_embeddertest.cpp
index 6454c34df1..952564db49 100644
--- a/fpdfsdk/fpdfedit_embeddertest.cpp
+++ b/fpdfsdk/fpdfedit_embeddertest.cpp
@@ -164,22 +164,6 @@ const char kExpectedPDF[] =
"379\r\n"
"%%EOF\r\n";
-int GetBlockFromString(void* param,
- unsigned long pos,
- unsigned char* buf,
- unsigned long size) {
- std::string* new_file = static_cast<std::string*>(param);
- if (!new_file || pos + size < pos)
- return 0;
-
- unsigned long file_size = new_file->size();
- if (pos + size > file_size)
- return 0;
-
- memcpy(buf, new_file->data() + pos, size);
- return 1;
-}
-
} // namespace
TEST_F(FPDFEditEmbeddertest, EmptyCreation) {