Lazy generate an "AP" when an Annot's hidden state changes
Now that Document::getAnnot works and annotation instances
can have its properties changed, consider the following
- A PDF content has an annotation without AP and
CPVT_GenerateAP is called to generate one.
- However the annotation also has its hidden flag set (/F 2),
and CPVT_GenerateAP bails out earlier, not generating an AP.
this annotation object, bounded to JS using Document::getAnnot(),
and set its "hidden" flag to false.
- At this point, the annotation should get drawn, but it does
not because its "AP" was never generated.
CL fixes this scenario by making PDFium able to lazy
generate APs, if needed.