diff options
Diffstat (limited to 'poppler/Page.h')
-rw-r--r-- | poppler/Page.h | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/poppler/Page.h b/poppler/Page.h index 7a20b55c..e548c867 100644 --- a/poppler/Page.h +++ b/poppler/Page.h @@ -107,8 +107,10 @@ public: ? separationInfo.getDict() : (Dict *)NULL; } Dict *getResourceDict() { return resources.isDict() ? resources.getDict() : (Dict *)NULL; } - void replaceResource(Object *obj1) - { obj1->shallowCopy(&resources); } + Object *getResourceDictObject() + { return &resources; } + void replaceResource(Object &&obj1) + { resources = std::move(obj1); } // Clip all other boxes to the MediaBox. void clipBoxes(); @@ -177,10 +179,11 @@ public: // Get resource dictionary. Dict *getResourceDict(); + Object *getResourceDictObject(); Dict *getResourceDictCopy(XRef *xrefA); // Get annotations array. - Object *getAnnots(Object *obj, XRef *xrefA = NULL) { return annotsObj.fetch((xrefA == NULL) ? xref : xrefA, obj); } + Object getAnnotsObject(XRef *xrefA = nullptr) { return annotsObj.fetch(xrefA ? xrefA : xref); } // Add a new annotation to the page void addAnnot(Annot *annot); // Remove an existing annotation from the page @@ -193,14 +196,14 @@ public: Annots *getAnnots(XRef *xrefA = NULL); // Get contents. - Object *getContents(Object *obj) { return contents.fetch(xref, obj); } + Object getContents() { return contents.fetch(xref); } // Get thumb. - Object *getThumb(Object *obj) { return thumb.fetch(xref, obj); } + Object getThumb() { return thumb.fetch(xref); } GBool loadThumb(unsigned char **data, int *width, int *height, int *rowstride); // Get transition. - Object *getTrans(Object *obj) { return trans.fetch(xref, obj); } + Object getTrans() { return trans.fetch(xref); } // Get form. FormPageWidgets *getFormWidgets(); @@ -211,7 +214,7 @@ public: double getDuration() { return duration; } // Get actions - Object *getActions(Object *obj) { return actions.fetch(xref, obj); } + Object getActions() { return actions.fetch(xref); } enum PageAdditionalActionsType { actionOpenPage, ///< Performed when opening the page |