summaryrefslogtreecommitdiff
path: root/BUILD.gn
AgeCommit message (Collapse)Author
2018-02-13Cleanup CXFA_Node ownershipDan Sinclair
Currently a CXFA_Node can be owned by the CXFA_Document root pointer, the CXFA_Document Purge list or as a child of another CXFA_Node. This makes it hard to know who currently owns what. This CL moves all ownership of nodes into a CXFA_NodeOwner class which CXFA_Document subclasses. The node owner always owns all nodes and is responsible for cleaning them up upon destruction. The destruction order is not guarenteed to be in tree order as nodes can be inserted and moved around the tree. Change-Id: I6b202b8e844999ba835093dcdd1a808938b6d9a8 Reviewed-on: https://pdfium-review.googlesource.com/26434 Reviewed-by: Tom Sepez <tsepez@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
2018-02-12Test if GC'd FXJS objects have their C-side counterparts cleaned up.Tom Sepez
Small correctness fix in other engine embeddertest. Change-Id: I6c2721921a659eef1b2f155ea1797722d37209d0 Reviewed-on: https://pdfium-review.googlesource.com/26270 Reviewed-by: dsinclair <dsinclair@chromium.org> Commit-Queue: Tom Sepez <tsepez@chromium.org>
2018-02-12Drop -Iv8 flag from pdfium buildTom Sepez
We converted the <v8.h> includes to "v8/include/v8.h" some revs back, so we need not explicitly tell the compiler to look there. Change-Id: Id71f1bad81a969eebf418c9d97b32864ea78480b Reviewed-on: https://pdfium-review.googlesource.com/26251 Reviewed-by: dsinclair <dsinclair@chromium.org> Commit-Queue: Tom Sepez <tsepez@chromium.org>
2018-02-09Speculative fix for build breakageTom Sepez
Make pdfium_embeddertests explicity depend on fxjs, which exposes v8 via public_deps, and hopefully stops the compiler from instantiating v8 code in our module. TBR=rharrison@chromium.org Change-Id: If6f2750a7a3b7a508275dedacfe07235ca8727f6 Reviewed-on: https://pdfium-review.googlesource.com/26250 Commit-Queue: Tom Sepez <tsepez@chromium.org> Reviewed-by: Tom Sepez <tsepez@chromium.org>
2018-02-09Rename fxjs_v8.{h,cpp} to cfxjs_engine.{h,cpp}Tom Sepez
Place the template map definitions entirely in .cpp file. Change-Id: I2643f1b99f5582b69aa985857c4aa6f9b5ab57c8 Reviewed-on: https://pdfium-review.googlesource.com/26150 Commit-Queue: Tom Sepez <tsepez@chromium.org> Reviewed-by: dsinclair <dsinclair@chromium.org>
2018-02-09Move CFX_V8 testing from embeddertest to unittest.Tom Sepez
Test the lowest layer without firing up the whole library. Requires firing up v8 in the unit test main, though. Move array buffer allocator to cfx_v8 to allow building isolates. Change-Id: I9a56d503a48e0e555d3310f2997fa12137695860 Reviewed-on: https://pdfium-review.googlesource.com/26130 Commit-Queue: Tom Sepez <tsepez@chromium.org> Reviewed-by: dsinclair <dsinclair@chromium.org>
2018-02-08Move cjs_v8.cpp to cfx_v8.cppTom Sepez
The layering should be CJS => CFXJS => CFX_V8 with the CJS name being higher up. Change-Id: Ic130f248906e9c4df641dd508389b0555786b999 Reviewed-on: https://pdfium-review.googlesource.com/26051 Commit-Queue: Tom Sepez <tsepez@chromium.org> Reviewed-by: dsinclair <dsinclair@chromium.org>
2018-02-07Make xfa_fxfa_parser target jumbo capable.Lei Zhang
Mechanically uniquify all the kFoo variables in xfa/fxfa/parser. BUG=pdfium:964 Change-Id: Iffe15015282d572147f31f2101fa0127f2198620 Reviewed-on: https://pdfium-review.googlesource.com/25890 Reviewed-by: dsinclair <dsinclair@chromium.org> Commit-Queue: Lei Zhang <thestig@chromium.org>
2018-02-06Extract classes in fx_bmp.h into their own filesRyan Harrison
BUG=chromium:808336 Change-Id: I3201805a374b5403149eca701714ef4369a2e337 Reviewed-on: https://pdfium-review.googlesource.com/25630 Reviewed-by: Henrique Nakashima <hnakashima@chromium.org> Commit-Queue: Ryan Harrison <rharrison@chromium.org>
2018-02-06Move core/fxcodec/lbmp/ -> core/fxcodec/bmp/Ryan Harrison
BUG=chromium:808336 Change-Id: Id721787dd77d1bcac6daf6e3c149f79e8d1d9fe4 Reviewed-on: https://pdfium-review.googlesource.com/25610 Reviewed-by: dsinclair <dsinclair@chromium.org> Commit-Queue: Ryan Harrison <rharrison@chromium.org>
2018-02-05Fold CJS_EmbedObj classes into CJS_Object classesDan Sinclair
This CL removes the CJS_EmbedObj class and various subclasses and folds the subclasses into their CJS_Object counterparts. Change-Id: If6b882a4995c0b1bf83ac783f5c27ba9216c2d5c Reviewed-on: https://pdfium-review.googlesource.com/25410 Commit-Queue: dsinclair <dsinclair@chromium.org> Reviewed-by: Tom Sepez <tsepez@chromium.org>
2018-02-02Fix IWYU errors in fpdfppo.cpp.Lei Zhang
Also rename the file to fpdf_ppo.cpp so it is consistent with the public header file name. This makes the linter happy. Change-Id: Ib3608c78111842579898c55f1399982ab2549310 Reviewed-on: https://pdfium-review.googlesource.com/24970 Commit-Queue: Lei Zhang <thestig@chromium.org> Reviewed-by: dsinclair <dsinclair@chromium.org>
2018-02-01Convert CFX_CSSPropertyTable to CFX_CSSDataRyan Harrison
This converts the existing class naming and references. The ::Entry struct is converted to ::Property. The GetBy* methods are renamed to GetPropertyBy*. Free functions from other parts of the CSS code base are merged into the class. GetCSSPropertyValueByName becomes ::GetPropertyValueByName with a return value of ::PropertyValue*. GetCSSLengthUnitByName becomes ::GetLengthUnitByName with a return value of ::LengthUnit*. GetCSSColorByName becomes ::GetColorByName with a return value of ::Color*. BUG=pdfium:998 Change-Id: I5b78c69d0fe53ad714ac3545cfdda8c26b95e4d5 Reviewed-on: https://pdfium-review.googlesource.com/25010 Reviewed-by: dsinclair <dsinclair@chromium.org> Reviewed-by: Henrique Nakashima <hnakashima@chromium.org> Commit-Queue: Ryan Harrison <rharrison@chromium.org>
2018-01-31Explicitly suppress -Wimplicit-fallthrough for pdfium.Nico Weber
No behavior change since that warning isn't enabled anywhere yet, and it's opt-in. This is a prerequisite for https://chromium-review.googlesource.com/c/chromium/src/+/895726 Bug: chromium:177475 Change-Id: I844455a19ed76b5deb0201a878576ab0d5418a71 Reviewed-on: https://pdfium-review.googlesource.com/24790 Reviewed-by: dsinclair <dsinclair@chromium.org> Commit-Queue: Nico Weber <thakis@chromium.org>
2018-01-31Clean up CSS property tableRyan Harrison
Reorganizes the free functions to be static methods on a class. Converts the Table struct to be an Entry struct defined in the class. Change-Id: I9eca0dfb15187af10cbe2dc4b4c2756d55d957be Reviewed-on: https://pdfium-review.googlesource.com/24712 Commit-Queue: Ryan Harrison <rharrison@chromium.org> Reviewed-by: dsinclair <dsinclair@chromium.org>
2018-01-29Add common base class between CXFA_FFComboBox and CXFA_FFListBoxDan Sinclair
This CL adds a CXFA_FFDropDown to serve as a base class for the CXFA_FFComboBox and CXFA_FFListBox and adds a virtual InsertItem and DeleteItem methods. Change-Id: I325ffc579ed42a4755bae0c4d18667f8a9458950 Reviewed-on: https://pdfium-review.googlesource.com/24550 Reviewed-by: Henrique Nakashima <hnakashima@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
2018-01-25Remove empty FF classesDan Sinclair
This CL removes the empty FFDraw and FFSubForm classes and uses the FFWidget base class directly. Change-Id: If65ee85fda78774bb90d6fec60ca5529cc37f3e0 Reviewed-on: https://pdfium-review.googlesource.com/23971 Reviewed-by: Henrique Nakashima <hnakashima@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
2018-01-24Put required DEFINE_PS_TABLES define in fx_freetype.cpp where it's used.chromium/3332chromium/3331Andrew Weintraub
This makes things more self-contained since we don't need the define in the BUILD.gn file. Change-Id: I27138f409521751f4994e6e9dc3c1a029e679836 Reviewed-on: https://pdfium-review.googlesource.com/23550 Reviewed-by: Lei Zhang <thestig@chromium.org> Reviewed-by: dsinclair <dsinclair@chromium.org> Commit-Queue: Lei Zhang <thestig@chromium.org>
2018-01-23Merge CXFA_WidgetAcc into CXFA_Nodechromium/3330Dan Sinclair
This CL merges CXFA_WidgetAcc into CXFA_Node. Change-Id: Iab52ca7f98c9dcd4ab089c61b8f1324a565bf647 Reviewed-on: https://pdfium-review.googlesource.com/23610 Reviewed-by: Henrique Nakashima <hnakashima@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
2018-01-23Convert CXFA_WidgetAccIterator to CXFA_ReadyNodeIteratorDan Sinclair
This CL converts the WidgetAcc iterator to return nodes in which the OnReady event has been fired. Change-Id: I5ec6809c1610ac3467019d8492121901d3845a37 Reviewed-on: https://pdfium-review.googlesource.com/23490 Reviewed-by: Ryan Harrison <rharrison@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
2018-01-23Tidy fxjs/cfxjse_isolatetracker.hTom Sepez
Move constructors to .cpp file. Remove unused member and its accessor method. Remove unused system includes. IsolateHandleRootContext is-a IsolateHandle (not has-a). Change-Id: Ifcba44f3ea7ad963fee731c24b2e79c5a8124539 Reviewed-on: https://pdfium-review.googlesource.com/23171 Commit-Queue: Tom Sepez <tsepez@chromium.org> Reviewed-by: Lei Zhang <thestig@chromium.org>
2018-01-22Support jumbo build in XFA targets.Lei Zhang
Except for the XFA parser, which has too many classes with the same constant names. BUG=pdfium:964 Change-Id: Iab1ac146017d13f63c0f4756d6e06035543eaba8 Reviewed-on: https://pdfium-review.googlesource.com/23174 Commit-Queue: Lei Zhang <thestig@chromium.org> Reviewed-by: dsinclair <dsinclair@chromium.org>
2018-01-22Break xfa target into smaller pieces.Lei Zhang
Change-Id: I3a30b3e945dd3147a85f0e057abd8768c9089331 Reviewed-on: https://pdfium-review.googlesource.com/23173 Reviewed-by: dsinclair <dsinclair@chromium.org> Commit-Queue: Lei Zhang <thestig@chromium.org>
2018-01-18Add jumbo build support for fxge and pwl.Lei Zhang
This completes jumbo build support for non-XFA builds. BUG=pdfium:964 Change-Id: Ife4ed23f9b438623581a863685014e64a06cf0d8 Reviewed-on: https://pdfium-review.googlesource.com/22775 Commit-Queue: Lei Zhang <thestig@chromium.org> Reviewed-by: dsinclair <dsinclair@chromium.org>
2018-01-16Move CXFA_ImageRenderer to own fileDan Sinclair
This CL Splits CL_ImageRenderer out of CXFA_FFWidget and moves to a separate file. Methods in CXFA_FFWidget are shuffled around to put the global methods at the top of the file and static methods in the anonymous namespace. Change-Id: I9887a5c9bf9fda63deead7ff785dc4ef3d7e15c8 Reviewed-on: https://pdfium-review.googlesource.com/23031 Reviewed-by: Henrique Nakashima <hnakashima@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
2018-01-16Add WriteBitmapToPng to EmbedderTest.Henrique Nakashima
This is a util method to output the png to a file for visually validating the result of an embedder test. Once validated, the md5 can be considered correct. Bug: pdfium:981 Change-Id: I544dfbf2e85295e6ca2cdf48d1bc3f0bd5f415e9 Reviewed-on: https://pdfium-review.googlesource.com/22990 Reviewed-by: Nicolás Peña Moreno <npm@chromium.org> Reviewed-by: dsinclair <dsinclair@chromium.org> Commit-Queue: Henrique Nakashima <hnakashima@chromium.org>
2018-01-12Add jumbo build support for fxbarcode.Lei Zhang
BUG=pdfium:964 Change-Id: Ic306a374bc9b710e2ac043eebe43504e5bd75926 Reviewed-on: https://pdfium-review.googlesource.com/22870 Reviewed-by: Tom Sepez <tsepez@chromium.org> Commit-Queue: Lei Zhang <thestig@chromium.org>
2018-01-11Add jumbo build support for fdrm, fpdfdoc and fxcrt.Lei Zhang
BUG=pdfium:964 Change-Id: Ifde885861aeafac803948bd537de826e2a3fddca Reviewed-on: https://pdfium-review.googlesource.com/22732 Commit-Queue: dsinclair <dsinclair@chromium.org> Reviewed-by: dsinclair <dsinclair@chromium.org>
2018-01-09Add initial jumbo build support.Lei Zhang
Convert a bunch of targets that just work. BUG=pdfium:964 Change-Id: I485be45e9f6c74c2bba88313da176a49b32b9bba Reviewed-on: https://pdfium-review.googlesource.com/21970 Reviewed-by: dsinclair <dsinclair@chromium.org> Commit-Queue: Lei Zhang <thestig@chromium.org>
2018-01-08Initialize V8 once in embedder testsDan Sinclair
This CL moves the initialization of the V8 platform to happen in the GTest environment so it's only run once. This takes the CFXJSE_FormCalcContextEmbedderTest Debug time from ~25s to ~19s on my local machine. Bug: pdfium:928 Change-Id: Ie8c27606721e7056de42e7d9474b0621f1e7212f Reviewed-on: https://pdfium-review.googlesource.com/22070 Reviewed-by: Tom Sepez <tsepez@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
2018-01-04Merge CXFA_WidgetData into CXFA_WidgetAccDan Sinclair
This CL merges the CXFA_WidgetData class into the only subclass, CXFA_WidgetAcc. Code has been updated as needed. Change-Id: I3f5bc83b1422bcbe065276b16bfb91e656f5c174 Reviewed-on: https://pdfium-review.googlesource.com/22252 Reviewed-by: Ryan Harrison <rharrison@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
2018-01-04Remove CXFA_DataDataDan Sinclair
This CL removes the CXFA_DataData base class and the functionality is moved to where it's needed. Change-Id: Ieba31aa924b9b513466144b31f0e1613923c50aa Reviewed-on: https://pdfium-review.googlesource.com/22250 Reviewed-by: Ryan Harrison <rharrison@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
2018-01-04Fold CXFA_EventData into CXFA_EventDan Sinclair
This CL removes the CXFA_EventData wrapper and puts the code into CXFA_Event. Change-Id: I799a641c434ff926f3ddade1f47845b5666dbbec Reviewed-on: https://pdfium-review.googlesource.com/21991 Reviewed-by: Ryan Harrison <rharrison@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
2018-01-04Fold CXFA_ExDataData into CXFA_ExDataDan Sinclair
This CL removes the CXFA_ExDataData wrapper and puts the code in CXFA_ExData directly. Change-Id: I9406d615a09fb431b5c620ed348f9976cf8dc72a Reviewed-on: https://pdfium-review.googlesource.com/22230 Reviewed-by: Henrique Nakashima <hnakashima@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
2018-01-04Fold CXFA_FontData into CXFA_FontDan Sinclair
This CL removes the CXFA_FontData wrapper and puts the functionality into CXFA_Font. Change-Id: Id7e3a71106816a05843a62645f5955a70f7eaeaa Reviewed-on: https://pdfium-review.googlesource.com/22113 Reviewed-by: Henrique Nakashima <hnakashima@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
2018-01-03Fold CXFA_FillData into CXFA_FillDan Sinclair
This CL removes the CXFA_FillData wrapper and puts the code directly in CXFA_Fill. Change-Id: I44ae8b53978b659480a4bb32719d086c7b91b49b Reviewed-on: https://pdfium-review.googlesource.com/22210 Reviewed-by: Ryan Harrison <rharrison@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
2018-01-03Fold CXFA_ImageData into CXFA_ImageDan Sinclair
This CL folds the CXFA_ImageData wrapper into CXFA_Image. Change-Id: I36596abc4dff7d17dc6ee13a857a084f41164c7a Reviewed-on: https://pdfium-review.googlesource.com/22190 Reviewed-by: Ryan Harrison <rharrison@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
2018-01-03Fold CXFA_LineData into CXFA_LineDan Sinclair
This CL merges the CXFA_LineData wrapper into CXFA_Line. Change-Id: If5299797a615d2c0abb661e72a9e036e69f96385 Reviewed-on: https://pdfium-review.googlesource.com/22112 Reviewed-by: Ryan Harrison <rharrison@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
2018-01-03Fold CXFA_BindItemsData into CXFA_BindItemsDan Sinclair
This CL merges CXFA_BindItemsData into the CXFA_BindItems class. Change-Id: I424274fcd6a9a4376d78794b1014988c3649602f Reviewed-on: https://pdfium-review.googlesource.com/22170 Reviewed-by: Henrique Nakashima <hnakashima@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
2018-01-03Fold CXFA_BindData into CXFA_BindDan Sinclair
This CL merges the CXFA_BindData wrapper into CXFA_Bind. Change-Id: I621955be2673938bf08c7897779311b776d0bf8b Reviewed-on: https://pdfium-review.googlesource.com/22131 Reviewed-by: Henrique Nakashima <hnakashima@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
2018-01-03Convert CXFA_StrokeData to CXFA_StrokeDan Sinclair
This CL changes CXFA_StrokeData to CXFA_Stroke and changes the inheritance form CXFA_DataData to CXFA_Node. The CXFA_EdgeData and CXFA_CornerData classes are removed and the node equivalents are changed to inherit from CXFA_Stroke. Change-Id: I8aa4365a8ed79c29c3a4c34879abe898a188b7de Reviewed-on: https://pdfium-review.googlesource.com/22151 Commit-Queue: dsinclair <dsinclair@chromium.org> Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
2018-01-03Fold CXFA_CaptionData into CXFA_CaptionDan Sinclair
This CL folds the CXFA_CaptionData wrapper class into CXFA_Caption. Change-Id: I65302656a89985dec4d0ec1f42b5eaa95d22aae2 Reviewed-on: https://pdfium-review.googlesource.com/22150 Reviewed-by: Ryan Harrison <rharrison@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
2018-01-03Change CXFA_BoxData to CXFA_BoxDan Sinclair
This CL renames CXFA_BoxData to CXFA_Box and sets it to inhert from CXFA_Node instead of CXFA_DataData. The CXFA_BoxData subclasses, CXFA_RectangleData, CXFA_BorderData and CXFA_ArcData classes are removed and the nodes now inherit from CXFA_Box. Change-Id: Ia0df7d56535b5d90be29f040180a5d5fc55a64e0 Reviewed-on: https://pdfium-review.googlesource.com/22091 Reviewed-by: Ryan Harrison <rharrison@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
2018-01-03Fold CXFA_OccurData into CXFA_OccurDan Sinclair
This CL folds the CXFA_OccurData wrapper into CXFA_Occur. Change-Id: I52e237e4f6b76f6915c397e924037562fd9eda6a Reviewed-on: https://pdfium-review.googlesource.com/22130 Reviewed-by: Ryan Harrison <rharrison@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
2018-01-03Fold CXFA_MarginData into CXFA_Marginchromium/3311Dan Sinclair
This CL removes the CXFA_MarginData wrapper and moves the methods directly to CXFA_Margin. Change-Id: I7c9e979fb78d0d356605f1318489daabcb8c32cd Reviewed-on: https://pdfium-review.googlesource.com/22110 Reviewed-by: Henrique Nakashima <hnakashima@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
2018-01-03Fold CXFA_CalculateData into CXFA_CalculateDan Sinclair
This CL folds CXFA_CalculateData into CXFA_Calculate as it is just a thin wrapper. Change-Id: I35efbee6c0244139a7ece19f3e8ee18bfb931dda Reviewed-on: https://pdfium-review.googlesource.com/22090 Reviewed-by: Henrique Nakashima <hnakashima@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
2017-12-19Fix some nits in build configs.Lei Zhang
Mostly to sort build rules. Change-Id: I2ee4d24089f9e51b0a61b1f30b424f5f7aab7d0a Reviewed-on: https://pdfium-review.googlesource.com/21730 Reviewed-by: Henrique Nakashima <hnakashima@chromium.org> Commit-Queue: Lei Zhang <thestig@chromium.org>
2017-12-14Fold CXFA_ParaData into CXFA_ParaDan Sinclair
This CL removes the CXFA_ParaData wrapper and folds the code into CXFA_Para. Change-Id: I86d139f1df48dcc80d28c7516b1bda95a59e94bd Reviewed-on: https://pdfium-review.googlesource.com/21270 Reviewed-by: Henrique Nakashima <hnakashima@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
2017-12-14Fold CXFA_ScriptData into CXFA_ScriptDan Sinclair
This CL removes the CXFA_ScriptData wrapper and uses CXFA_Script directly. Change-Id: I1f1932ef96ee4a24407de7eb1d68b8631a5a67ea Reviewed-on: https://pdfium-review.googlesource.com/21173 Commit-Queue: dsinclair <dsinclair@chromium.org> Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
2017-12-14Fold CXFA_SubmitData into CXFA_SubmitDan Sinclair
CXFA_SubmitData is a thin wrapper around CXFA_Submit. This CL folds the two classes together. Change-Id: I867b6db067786d232df2a25c1ba7b29d6d454f8e Reviewed-on: https://pdfium-review.googlesource.com/21190 Commit-Queue: dsinclair <dsinclair@chromium.org> Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>