Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(297)

Unified Diff: src/pdf/SkPDFCatalog.h

Issue 846023003: In SkPDFDocument::emitPDF(), stop pre-calculating file offsets. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: nit: space between functions Created 5 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/pdf/SkPDFCatalog.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/pdf/SkPDFCatalog.h
diff --git a/src/pdf/SkPDFCatalog.h b/src/pdf/SkPDFCatalog.h
index c7c6d6e2995652f0c0c8260381bbfe4d1feaaf15..ecefd0a0728ab4252ac42f711cd2937f01e7663d 100644
--- a/src/pdf/SkPDFCatalog.h
+++ b/src/pdf/SkPDFCatalog.h
@@ -37,12 +37,11 @@ public:
SkPDFObject* addObject(SkPDFObject* obj, bool onFirstPage);
/** Inform the catalog of the object's position in the final stream.
- * The object should already have been added to the catalog. Returns
- * the object's size.
+ * The object should already have been added to the catalog.
* @param obj The object to add.
* @param offset The byte offset in the output stream of this object.
*/
- size_t setFileOffset(SkPDFObject* obj, off_t offset);
+ void setFileOffset(SkPDFObject* obj, off_t offset);
/** Output the object number for the passed object.
* @param obj The object of interest.
@@ -77,16 +76,9 @@ public:
*/
SkPDFObject* getSubstituteObject(SkPDFObject* object);
- /** Set file offsets for the resources of substitute objects.
- * @param fileOffset Accumulated offset of current document.
- * @param firstPage Indicate whether this is for the first page only.
- * @return Total size of resources of substitute objects.
+ /** get the resources of substitute objects.
*/
- off_t setSubstituteResourcesOffsets(off_t fileOffset, bool firstPage);
-
- /** Emit the resources of substitute objects.
- */
- void emitSubstituteResources(SkWStream* stream, bool firstPage);
+ SkTSet<SkPDFObject*>* getSubstituteList(bool firstPage);
private:
struct Rec {
@@ -130,8 +122,6 @@ private:
int findObjectIndex(SkPDFObject* obj) const;
int assignObjNum(SkPDFObject* obj);
-
- SkTSet<SkPDFObject*>* getSubstituteList(bool firstPage);
};
#endif
« no previous file with comments | « no previous file | src/pdf/SkPDFCatalog.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698