[poppler] Branch 'xpdf303merge' - poppler/Annot.cc poppler/Annot.h

Carlos Garcia Campos carlosgc at kemper.freedesktop.org
Sun Sep 18 01:53:17 PDT 2011


 poppler/Annot.cc |    2 +-
 poppler/Annot.h  |    2 --
 2 files changed, 1 insertion(+), 3 deletions(-)

New commits:
commit 72a7736389cbe36c1f8a526f1a659cae1a3f85a3
Author: Carlos Garcia Campos <carlosgc at gnome.org>
Date:   Sun Sep 18 10:47:51 2011 +0200

    xpdf303: No need to cache optContentConfig object in Annot

diff --git a/poppler/Annot.cc b/poppler/Annot.cc
index d0f8231..2827e75 100644
--- a/poppler/Annot.cc
+++ b/poppler/Annot.cc
@@ -1010,7 +1010,6 @@ void Annot::initialize(PDFDoc *docA, Dict *dict) {
   }
   obj1.free();
 
-  optContentConfig = doc->getCatalog()->getOptContentConfig();
   dict->lookupNF("OC", &oc);
   if (!oc.isRef() && !oc.isNull()) {
     error (errSyntaxError, -1, "Annotation OC value not null or dict: {0:d}", oc.getType());
@@ -1338,6 +1337,7 @@ GBool Annot::isVisible(GBool printing) {
   }
 
   // check the OC
+  OCGs *optContentConfig = doc->getCatalog()->getOptContentConfig();
   if (optContentConfig && oc.isRef()) {
     if (! optContentConfig->optContentIsVisible(&oc))
       return gFalse;
diff --git a/poppler/Annot.h b/poppler/Annot.h
index 64ad7f0..c1188d0 100644
--- a/poppler/Annot.h
+++ b/poppler/Annot.h
@@ -50,7 +50,6 @@ class FormFieldChoice;
 class PDFRectangle;
 class Movie;
 class LinkAction;
-class OCGs;
 class Sound;
 
 enum AnnotLineEndingStyle {
@@ -553,7 +552,6 @@ protected:
                          //   for the normal appearance
   GooString *appearState;           // AS
   int treeKey;                      // Struct Parent;
-  OCGs *optContentConfig;           // Optional content config
   Object oc;                        // OC
 
   PDFDoc *doc;


More information about the poppler mailing list