Age | Commit message (Collapse) | Author |
|
R=thakis@chromium.org
Review URL: https://codereview.chromium.org/1547833002 .
|
|
These are synonyms for CFX_Matrix.
Nothing but sed and manual deletion of 2 #defines in
fpdf_parser.h and fx_coordinates.h
R=thestig@chromium.org
Review URL: https://codereview.chromium.org/1513363002 .
|
|
Change some master code to line up better with XFA, so
that the XFA changes are additive when possible, rather
than replacements.
R=thestig@chromium.org
Review URL: https://codereview.chromium.org/1468253005 .
|
|
Do some IWYU to fix build errors due to files that have no #includes but
just happened to work previously because the #includes were in the right
order.
R=tsepez@chromium.org
Review URL: https://codereview.chromium.org/1407423004 .
|
|
R=tsepez@chromium.org
Review URL: https://codereview.chromium.org/1415803007 .
|
|
- In non-standalone builds, use the provided jpeg library.
- Run gn format over all the GN files.
- Also roll DEPS for buildtools to c2f2598.
BUG=541704
R=tsepez@chromium.org
Review URL: https://codereview.chromium.org/1425153006 .
|
|
- Remove dead code
- Stop using CFX_PtrArray
- Mark more things const
- Fix style nits
R=tsepez@chromium.org
Review URL: https://codereview.chromium.org/1425093003 .
|
|
R=tsepez@chromium.org, thestig@chromium.org
Review URL: https://codereview.chromium.org/1425233002 .
|
|
Previously, blur event actions could potentially touch deleted PageViews
as CPDFSDK_Document deletes the PageViews one by one.
This also fixes a related issue: CPDFSDK_Document::SetFocusAnnot no
longer does anything if the document is being destroyed. Otherwise, it
eventually tries to use m_pEnv->GetSDKDocument() at which point has
already been set to NULL by FPDFDOC_ExitFormFillEnvironment.
R=tsepez@chromium.org, thestig@chromium.org
BUG=512445
Review URL: https://codereview.chromium.org/1414353007 .
|
|
The original XFA version was correct, and the master version here is
wrong. The two versions are now in sync, but incorrect.
So we need to fix this here and then merge to XFA again.
Also fix what are now incorrect uses of CountAnnots() and do some
cleanups.
BUG=543049
R=tsepez@chromium.org
Review URL: https://codereview.chromium.org/1413973011 .
|
|
This reverts commit 9dd9439d23d44d105db0950e33af0cc913a6cece.
BUG=536967
TBR=tsepez@chromium.org
Review URL: https://codereview.chromium.org/1421583005 .
|
|
The original XFA version was correct, and the master version here is
wrong. The two versions are now in sync, but incorrect. So we need to
fix this here and then merge to XFA again.
BUG=536967
R=tsepez@chromium.org
Review URL: https://codereview.chromium.org/1406183007 .
|
|
R=tsepez@chromium.org
Review URL: https://codereview.chromium.org/1411203007 .
|
|
- Add new CPDFSDK_Document::GetPDFDocument()
- FPDFDocumentFromCPDFDocument() to match XFA
- rename some JS variables to be consistent with XFA
- remove unused param from CJS_GlobalData().
- kill dead code used XFA only.
R=thestig@chromium.org
Review URL: https://codereview.chromium.org/1413883005 .
|
|
R=thestig@chromium.org
Review URL: https://codereview.chromium.org/1401423004 .
|
|
Nothing but sed.
FXJS is a layer that makes it easier to define objects in V8, but has
no knowledge of PDF-specific native objects. It could in theory be used
to implement other sets of native objects.
JS is the layer that implements PDF-specific native objects on top of
FXJS.
Therefore, the classes used to interface to JS should be named using
IJS_. IFXJS_ is reserved for someday adding better API for FXJS iteslf.
R=thestig@chromium.org
Review URL: https://codereview.chromium.org/1386173002 .
|
|
The Factory Design Pattern isn't buying us anything here over just new'ing
the object we want.
R=thestig@chromium.org
Review URL: https://codereview.chromium.org/1360523004 .
|
|
R=tsepez@chromium.org
Review URL: https://codereview.chromium.org/1287193005 .
|
|
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 .
|
|
This reverts commit ff46aaf499edcf153ee2f57c7016587aa96dcfa0.
TBR=thestig@chromium.org
Review URL: https://codereview.chromium.org/1255293002 .
|
|
Try to reland this patch after fixing underlying issues that
caused it to be reverted.
fx_system.h is the only manual edit.
R=thestig@chromium.org
Review URL: https://codereview.chromium.org/1258093002 .
|
|
This reverts commit 320b2313d19869333ed453af546e61a9fc2b81c9.
Reason for revert: build failure.
TBR=thestig@chromium.org
Review URL: https://codereview.chromium.org/1255693002 .
|
|
Fully automatic change, execpt for cleanup in fx_system.h
R=thestig@chromium.org
Review URL: https://codereview.chromium.org/1254703002 .
|
|
- untabify as encountered.
- Only put single-statement method in .h file, move more
complex methods to .cpp (counting an if without braces as
a single statement, killing braces as needed).
- Move invariant arguments to constructor and make
corresponding members const.
- Make all members private and add accessor methods.
- Make existing accessor methods const where possible.
- Kill meaningless asserts.
- Add helper functions in place of duplicate code.
- Rename GetCurrentDoc() to GetSDKDocument(), since the class
has two document members, one of CPDF_Document and one of
CPDFSDK_Document, making it clear which one you get.
- Simplify some logic with early returns.
R=thestig@chromium.org
Review URL: https://codereview.chromium.org/1235393002 .
|
|
R=jam@chromium.org
Review URL: https://codereview.chromium.org/1198903002.
|
|
1) Document::deletePages()
2) CPDFSDK_Document::DeletePages()
3) Document::removeIcon()
4) IconTree::DeleteIconElement()
Originally (1) called (2), but only when FOXIT_CHROME_BUILD was not
defined. Since it was always defined for PDFium, this was effectively
dead code the whole time. Ditto for (3) and (4). The functions were
deemed unsafe in https://crbug.com/67100
R=jam@chromium.org
Review URL: https://codereview.chromium.org/1193323002.
|
|
R=tsepez@chromium.org
Review URL: https://codereview.chromium.org/1181593003.
|
|
R=tsepez@chromium.org
Review URL: https://codereview.chromium.org/1176333002.
|
|
This involves fixing some multiple variable per line
declarations, as the textually-substituted "*" applies
only to the first one.
This involves moving some consts around following the
substitution.
This involves replacing some typedefs used as constructors
with better code.
R=thestig@chromium.org
Review URL: https://codereview.chromium.org/1171733003
|
|
- include system headers first and alphabetize.
- remove unsupported FX_WIN32_MOBILE symbol.
- actually define a FX_WIN64 symbol and make consistent.
- use final/override, not FX_FINAL.
- let stdint.h resolve FX_WORDSIZE concerns.
- unused FX_ERR and FX_SUCCESS() macros.
- unused FX_LSB_FIRST macro.
- outline FX type deprecation plan.
R=thestig@chromium.org
Review URL: https://codereview.chromium.org/1169963003
|
|
Get rid of leading _CAPITAL identifiers.
A large number of these didn't actually match the filename.
R=thestig@chromium.org
Review URL: https://codereview.chromium.org/1160443004
|
|
These are the only files that embedders of PDFium should be including.
They are entirely self-contained, and compile cleanly against -Wall so
as to not offend the code that may include them.
Having done this, we can see that chromium is pulling in two additional
files from the fpdfsdk/include/pdfwindow directory, which is not guaranteed
to work.
A few files are renamed, adding an "_" to make the names consistent.
The exception is fpdfview, which is doc'd as such in the doc.
Naturally, paths will need updating in a handful of files in chrome
when this rolls in.
BUG=pdfium:154
R=thestig@chromium.org
Review URL: https://codereview.chromium.org/1135913002
|
|
This provides no benefit, and reduces transparency.
Along the way:
Kill off some unused/commented-out code.
Return void where a bool return doesn't make sense.
Remove a pointless template type.
Remove now unused constants and types.
R=thestig@chromium.org
Review URL: https://codereview.chromium.org/971033002
|
|
Note that this work was done opposite the usual branch order, because I
didn't want to kill things in master that turned out to be in use in XFA.
Original Review URL: https://codereview.chromium.org/883393007
TBR=jam@chromium.org
Review URL: https://codereview.chromium.org/903893002
|
|
BUG=410326
R=tsepez@chromium.org
Review URL: https://codereview.chromium.org/594403003
|
|
If somehow different length values could be obtained by two successive calls
to Doc_getFilePath() (and FieldBrowse() for that matter), and the method is
true to the API documentation that says "The return value always indicated
number of bytes required for the buffer, even when there is no buffer
specified, or the buffer size is less then required", then it is possible
to get a returned length describing memory beyond the current buffer.
We can make the corresponding JS_docGetFilePath() method more robust against
this case by applying better checks to the returned value.
This probably is unrelated since ASAN seems to be flagging the corresponding bug
as UAF, but doesn't hurt to make things more robust.
BUG=392956
R=jun_fang@foxitsoftware.com
Review URL: https://codereview.chromium.org/423233002
|
|
Calling `delete` on an object of a type that has virtual functions but
not a virtual destructor is questionable: Since the object has virtual functions,
it likely has subclasses, so if it's deleted through the base pointer and the
destructor isn't virtual, the subclass destructor won't be called.
In most cases, the classes getting deleted can just be marked final to tell
the compiler that it can't possibly have subclasses (this also enables the
compiler to generate better code).
Two classes didn't have any sub- or superclasses but virtual functions -
this doesn't make sense, so make all methods of these classes non-virtual.
(Also delete an unused function on one of the two classes.)
In one case, a class actually did have a subclass that needs to be deleted
virtually, so mark one destructor as virtual.
BUG=none
R=bo_xu@foxitsoftware.com
Review URL: https://codereview.chromium.org/370853002
|
|
BUG=382639
R=mdempsky@chromium.org
Review URL: https://codereview.chromium.org/354673002
|
|
|
|
|