[poppler] poppler/Form.cc poppler/Form.h

Carlos Garcia Campos carlosgc at kemper.freedesktop.org
Wed Mar 9 11:54:47 PST 2011


 poppler/Form.cc |   22 ----------------------
 poppler/Form.h  |    2 --
 2 files changed, 24 deletions(-)

New commits:
commit f0ec3bedc5490aa35e54563019fcf2c3f8b7647d
Author: Carlos Garcia Campos <carlosgc at gnome.org>
Date:   Wed Mar 9 20:54:15 2011 +0100

    forms: Remove unused method FormWidget::updateField()

diff --git a/poppler/Form.cc b/poppler/Form.cc
index acd1b2c..d553436 100644
--- a/poppler/Form.cc
+++ b/poppler/Form.cc
@@ -123,28 +123,6 @@ void FormWidget::decodeID (unsigned id, unsigned* pageNum, unsigned* fieldNum)
   *fieldNum = (id << 4*sizeof(unsigned)) >> 4*sizeof(unsigned);
 }
 
-void FormWidget::updateField (const char *key, Object *value)
-{
-  Object *obj1;
-  Ref ref1;
-  Object obj2;
-
-  if (obj.getDict()->lookup ("FT", &obj2)->isName ()) {
-    // It's a composed (annot + field) dict
-    obj1 = &obj;
-    ref1 = ref;
-  } else {
-    // It's an annot dict, we have to modify the Field (parent) dict
-    obj1 = field->getObj ();
-    ref1 = field->getRef ();
-  }
-  obj2.free ();
-
-  obj1->getDict ()->set (const_cast<char*>(key), value);
-  //notify the xref about the update
-  xref->setModifiedObject(obj1, ref1);
-}
-
 GooString *FormWidget::getPartialName() const {
   return field->getPartialName();
 }
diff --git a/poppler/Form.h b/poppler/Form.h
index adcf646..8f0eeb3 100644
--- a/poppler/Form.h
+++ b/poppler/Form.h
@@ -112,8 +112,6 @@ public:
 protected:
   FormWidget(XRef *xrefA, Object *aobj, unsigned num, Ref aref, FormField *fieldA);
 
-  void updateField (const char *key, Object *value);
-
   AnnotWidget *widget;
   FormField* field;
   FormFieldType type;


More information about the poppler mailing list