summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2015-08-14Add new public APIs to find the z-order for links and widgets.chromium/2485chromium/2484Lei Zhang
- Implement FPDFLink_GetLinkZOrderAtPoint(). - Implement FPDFPage_FormFieldZOrderAtPoint(). - Mark FPDPage_HasFormFieldAtPoint() as deprecated. - Modify CPDF_LinkList and CPDF_InterForm to support new APIs. - Clean up dead code in CPDF_LinkList and CPDF_InterForm. BUG=chromium:515837 R=jun_fang@foxitsoftware.com, tsepez@chromium.org Review URL: https://codereview.chromium.org/1278053004 .
2015-08-14Don't bother checking pointers before delete[] and FX_Free().Lei Zhang
R=tsepez@chromium.org Review URL: https://codereview.chromium.org/1297713003 .
2015-08-14Use override in more classes in fpdfsdk/Lei Zhang
R=tsepez@chromium.org Review URL: https://codereview.chromium.org/1287193005 .
2015-08-14Use override in more classes in core/Lei Zhang
R=tsepez@chromium.org Review URL: https://codereview.chromium.org/1292613003 .
2015-08-14Cleanup: Remove unused CPDF_Metadata::m_pDoc.Lei Zhang
Also remove unused kAddinNameCJK variable. R=tsepez@chromium.org Review URL: https://codereview.chromium.org/1296513003 .
2015-08-14CPDF_ModuleMgr::m_SecurityHandlerMap only used by dead code.Tom Sepez
R=thestig@chromium.org Review URL: https://codereview.chromium.org/1289693008 .
2015-08-13Fix build after commit 22ece1a. Too many if's.Lei Zhang
TBR=tsepez@chromium.org Review URL: https://codereview.chromium.org/1294723002 .
2015-08-13Remove last uses of FOXIT_CHROME_BUILD.Lei Zhang
BUG=pdfium:46 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/1294693002 .
2015-08-13Cleanup: s/Torelance/Tolerance/Lei Zhang
R=tsepez@chromium.org TBR=tsepez@chromium.org Review URL: https://codereview.chromium.org/1294713002 .
2015-08-13OutputText() is dead code.Tom Sepez
R=thestig@chromium.org Review URL: https://codereview.chromium.org/1291213003 .
2015-08-13Tidy up JS_Object.h and JS_Object.cpp.Tom Sepez
R=thestig@chromium.org Review URL: https://codereview.chromium.org/1293673003 .
2015-08-13Kill JS_TIMER_MAPARRAYTom Sepez
R=thestig@chromium.org Review URL: https://codereview.chromium.org/1286383004 .
2015-08-13Cleanup: Remove unused CPDF_Stream::Clone().Lei Zhang
Cloning a CPDF_Stream actually happens via CPDF_Object::Clone(). Transitively, remove: - GetStreamFilter() -- all the filters. R=jam@chromium.org Review URL: https://codereview.chromium.org/1288543002 .
2015-08-13Make standalone PDFium DEPS pull clang-format.Tom Sepez
R=thakis@chromium.org Review URL: https://codereview.chromium.org/1297453002 .
2015-08-13Remove if checks after new.Lei Zhang
R=tsepez@chromium.org Review URL: https://codereview.chromium.org/1287863002 .
2015-08-13Suppress -Wunused-function for pdfium's third-party libraries.Nico Weber
Also add a missing header file. BUG=505316 R=thestig@chromium.org Review URL: https://codereview.chromium.org/1285123003 .
2015-08-13Allow external font-path configuration from pdfium_test.Tom Sepez
R=thestig@chromium.org Committed: https://pdfium.googlesource.com/pdfium/+/d8b5e73d8609b74e6a995ee1768d20d47bd4b089 Review URL: https://codereview.chromium.org/1268323004 .
2015-08-13Revert "Allow external font-path configuration from pdfium_test."Tom Sepez
This reverts commit d8b5e73d8609b74e6a995ee1768d20d47bd4b089. Broke corpus tests TBR=thestig@chromium.org Review URL: https://codereview.chromium.org/1292153002 .
2015-08-13Allow external font-path configuration from pdfium_test.Tom Sepez
R=thestig@chromium.org Review URL: https://codereview.chromium.org/1268323004 .
2015-08-11Fix a small leak in CPDF_DataAvail::CheckTrailer().Lei Zhang
R=tsepez@chromium.org Review URL: https://codereview.chromium.org/1278713003 .
2015-08-11Fix some sign comparison warnings.Lei Zhang
R=tsepez@chromium.org Review URL: https://codereview.chromium.org/1279493003 .
2015-08-11Remove dead code from CPDF_Metadata. Add missing nullptr check.Lei Zhang
BUG=pdfium:117 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/1282653002 .
2015-08-10Cleanup: Mark methods with the override keyword.chromium/2483chromium/2482chromium/2481chromium/2480chromium/2479Lei Zhang
- Delete unneeded CFFL_ComboBox::CanCopy() and friends. - Delete unneeded CFFL_FormFiller::CanCopy() and friends. - Delete unneeded CFFL_TextField::CanCopy() and friends. - Delete unneeded FormFiller::DoCopy() and friends. - Rename CFFL_FormFiller::On{Set,Kill}Focus to avoid conflicts. BUG=pdfium:185 R=thakis@chromium.org Review URL: https://codereview.chromium.org/1283493004 .
2015-08-07Really Really fix tests broken at 9778206.Tom Sepez
Stub out failing platform entirely TBR=thestig@chromium.org Review URL: https://codereview.chromium.org/1276333006 .
2015-08-07Really fix tests broken at 9778206.Tom Sepez
Stub out failing platform. TBR=thestig@chromium.org Review URL: https://codereview.chromium.org/1280043005 .
2015-08-07Fix win unit tests broken at 9778206.Tom Sepez
Windows uses the system implementation of itoa which goes to 36. TBR=thestig@chromium.org Review URL: https://codereview.chromium.org/1285433002 .
2015-08-07Fix FXSYS_itoa() implementation.Tom Sepez
I thought about removing it, but decided to fix it instead until c++11 hits and there may be better alternatives. Remove unused variants. BUG=517854 R=brucedawson@chromium.org, thestig@chromium.org Review URL: https://codereview.chromium.org/1274423003 .
2015-08-07Convert all files on the master branch to unix line endings.Nico Weber
Luckily, it's just one file. BUG=none R=tsepez@chromium.org Review URL: https://codereview.chromium.org/1281923004 .
2015-08-06clang-format all pdfium code, again.Nico Weber
Also add a presubmit that checks for this so I don't have to keep doing it. No behavior change. Generated by: find . -name '*.cpp' -o -name '*.h' | \ grep -E -v 'third_party|thirdparties|lpng_v163' | \ xargs ../../buildtools/mac/clang-format -i BUG=none R=thestig@chromium.org Review URL: https://codereview.chromium.org/1272653005 .
2015-08-06Add CFX_FontFaceInfo constructor.chromium/2478chromium/2477chromium/2476chromium/2475Tom Sepez
(Having renamed CFontFaceInfo to follow naming pattern). Also cleanup some initialization-order noise in CFX_FontMapper. R=thestig@chromium.org Review URL: https://codereview.chromium.org/1277883004 .
2015-08-05Early object closing in PDF via premature 'endobj' keywordJUN FANG
Adobe acrobat defines keywords "\nendstream\n" and "\nendobj\n" in object's stream. However, Pdfium searches "endstream" and "endobj" as the keywords in the streams of objects. Some words like "(endstream)" are wrongly treated as keywords in pdfium. This fix follows Adobe's solution. BUG=493126 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/1219133005 .
2015-08-05Remove the unused IFX_StreamRead::SetRange() mechanism.Tom Sepez
This, in turn make m_bUseRange always false, so remove it. R=thestig@chromium.org Review URL: https://codereview.chromium.org/1274883002 .
2015-08-05CPDF_Parser shouldnt be in the business of opening filesTom Sepez
Move that operation closer to the embedder's call. R=thestig@chromium.org Review URL: https://codereview.chromium.org/1269073003 .
2015-08-05FPDF_Creator can only create file through embedder-supplied callback.Tom Sepez
Hence, some of the routines taking filename strings are unused. This, in turn allows us to get rid of some other fopen-ishy looking things inside the library. R=thestig@chromium.org Review URL: https://codereview.chromium.org/1264423003 .
2015-08-05Don't dispose the isolate if its provided by the embedderchromium/2474Jochen Eisinger
BUG=chromium:515718 R=thestig@chromium.org Review URL: https://codereview.chromium.org/1269783005 .
2015-08-04Add a license header for testing/tools/make_expected.sh.Lei Zhang
R=tsepez@chromium.org Review URL: https://codereview.chromium.org/1259963005 .
2015-08-04Remove stringify macro (#) from JS_STATIC_CONST_ENTRY_*.Tom Sepez
R=thestig@chromium.org Review URL: https://codereview.chromium.org/1256283005 .
2015-08-04Add a .clang-format config file.Nico Weber
This is the .clang-format file I used to format everything. BUG=none R=tsepez@chromium.org Review URL: https://codereview.chromium.org/1260183009 .
2015-08-04Quick fix in Consts.cpp to make tests pass after the clang-format CL.Lei Zhang
TBR=tsepez@chromium.org Review URL: https://codereview.chromium.org/1269223002 .
2015-08-04clang-format all pdfium code.Nico Weber
No behavior change. Generated by: find . -name '*.cpp' -o -name '*.h' | \ grep -E -v 'third_party|thirdparties|lpng_v163' | \ xargs ../../buildtools/mac/clang-format -i See thread "tabs vs spaces" on pdfium@googlegroups.com for discussion. BUG=none R=tsepez@chromium.org Review URL: https://codereview.chromium.org/1265503005 .
2015-07-31Kill FX_HFILETom Sepez
FX_HFILE, and the routines that operate on it, are unused. R=thestig@chromium.org Review URL: https://codereview.chromium.org/1259123008 .
2015-07-31Name IFX_SysFontInfo subclasses consistently.Tom Sepez
Nearly a naming-only change, but add one argument to constructor. grep now shows: class CFX_AndroidFontInfo : public IFX_SystemFontInfo class CFX_Win32FontInfo final : public IFX_SystemFontInfo class CFX_ExternalFontInfo final : public IFX_SystemFontInfo class CFX_FolderFontInfo : public IFX_SystemFontInfo class CFX_MacFontInfo : public CFX_FolderFontInfo class CFX_LinuxFontInfo : public CFX_FolderFontInfo R=thestig@chromium.org Review URL: https://codereview.chromium.org/1257743005 .
2015-07-31Kill IFX_FontMapperTom Sepez
The design envisioned two kinds of font mappers: internal (of type CFX_FontMapper), and external, both of which implement a common interface. But there isn't any means of making an external one, so the interface is redundant. IFX_FontMapper also appears in an apple-specific struct, but was never non-null or used in any way. The CFX_FontMapper class provides its own mechanism to include platform-specific features, as it turns out. R=thestig@chromium.org Review URL: https://codereview.chromium.org/1259123005 .
2015-07-31Roll corpus to 2ddcfbd.Tom Sepez
TBR=thestig@chromium.org Review URL: https://codereview.chromium.org/1266833003 .
2015-07-30Add simple script to regenerate expected results.Tom Sepez
(I've been doing this by hand for far too long). R=thestig@chromium.org Review URL: https://codereview.chromium.org/1264873005 .
2015-07-30Fix return check in CFX_FolderFontInfo::ScanFile() fread.Tom Sepez
If you want to check the number of bytes read, you need to change the order of arguments. TEST=testing/corpus/fx/mulobj/1/1_10_watermark.pdf.0.png R=thestig@chromium.org Review URL: https://codereview.chromium.org/1262453006 .
2015-07-30Re-enable successful tests.Tom Sepez
TBR=thestig@chromium.org Review URL: https://codereview.chromium.org/1258203005 .
2015-07-30New suppressions for bundled freetypeTom Sepez
TBR=thestig@chromium.org Review URL: https://codereview.chromium.org/1255933006 .
2015-07-30Use bundled freetype for the pdfium_test binary.Tom Sepez
But use platform freetype for library itself according to the rules for the platform. This should greatly reduce per-platform diffs in the corpus tests, but requires that the corpus be rolled at the same time. When this rolls into chromium, its src/BUILD.gn will need to be updated to say third_party:fx_freetype instead of third_party:freetype. R=jam@chromium.org Review URL: https://codereview.chromium.org/1267493005 .
2015-07-28Missing bExact -> iExact conversionsTom Sepez
This is the cause of the mac embeddertest failure when fx_bool is replaced by bool (an incorrect overload). The types still match on master, prior to the conversion, so it's not noticed. Find other instances as well. R=thestig@chromium.org Review URL: https://codereview.chromium.org/1262683003 .