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

Unified Diff: core/include/fpdfapi/fpdf_page.h

Issue 1257503002: FX_BOOL not always 0 or 1 in CPDF_PageObjects::m_ParserState (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Created 5 years, 5 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 | core/src/fpdfapi/fpdf_page/fpdf_page.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: core/include/fpdfapi/fpdf_page.h
diff --git a/core/include/fpdfapi/fpdf_page.h b/core/include/fpdfapi/fpdf_page.h
index 7aed626faec58a30670f96967a3ae661ddd27cbc..140eab00d61a8dcb824b5478561d23ca8758e1c9 100644
--- a/core/include/fpdfapi/fpdf_page.h
+++ b/core/include/fpdfapi/fpdf_page.h
@@ -24,37 +24,22 @@ class CPDF_StreamContentParser;
#define PDFTRANS_GROUP 0x0100
#define PDFTRANS_ISOLATED 0x0200
#define PDFTRANS_KNOCKOUT 0x0400
-#define PDF_CONTENT_NOT_PARSED 0
-#define PDF_CONTENT_PARSING 1
-#define PDF_CONTENT_PARSED 2
+
class CPDF_PageObjects
{
public:
-
CPDF_PageObjects(FX_BOOL bReleaseMembers = TRUE);
-
~CPDF_PageObjects();
-
-
-
void ContinueParse(IFX_Pause* pPause);
- int GetParseState() const
Tom Sepez 2015/07/23 21:00:41 note: dead code.
- {
- return m_ParseState;
- }
-
FX_BOOL IsParsed() const
{
- return m_ParseState == PDF_CONTENT_PARSED;
+ return m_ParseState == CONTENT_PARSED;
}
int EstimateParseProgress() const;
Lei Zhang 2015/07/23 21:08:59 Also dead, along with CPDF_ContentParser::Estimate
-
-
-
FX_POSITION GetFirstObjectPosition() const
{
return m_ObjectList.GetHeadPosition();
@@ -89,10 +74,6 @@ public:
CPDF_PageObject* GetObjectByIndex(int index) const;
-
-
-
-
FX_POSITION InsertObject(FX_POSITION posInsertAfter, CPDF_PageObject* pNewObject);
void Transform(const CFX_AffineMatrix& matrix);
@@ -105,17 +86,11 @@ public:
CFX_FloatRect CalcBoundingBox() const;
CPDF_Dictionary* m_pFormDict;
-
CPDF_Stream* m_pFormStream;
-
CPDF_Document* m_pDocument;
-
CPDF_Dictionary* m_pPageResources;
-
CPDF_Dictionary* m_pResources;
-
CFX_FloatRect m_BBox;
-
int m_Transparency;
protected:
@@ -123,18 +98,22 @@ protected:
friend class CPDF_StreamContentParser;
friend class CPDF_AllStates;
- CFX_PtrList m_ObjectList;
+ enum ParseState {
+ CONTENT_NOT_PARSED,
+ CONTENT_PARSING,
+ CONTENT_PARSED
+ };
- FX_BOOL m_bBackgroundAlphaNeeded;
-
- FX_BOOL m_bReleaseMembers;
void LoadTransInfo();
void ClearCacheObjects();
+ CFX_PtrList m_ObjectList;
+ FX_BOOL m_bBackgroundAlphaNeeded;
+ FX_BOOL m_bReleaseMembers;
CPDF_ContentParser* m_pParser;
-
- FX_BOOL m_ParseState;
+ ParseState m_ParseState;
};
+
class CPDF_Page : public CPDF_PageObjects, public CFX_PrivateData
{
public:
« no previous file with comments | « no previous file | core/src/fpdfapi/fpdf_page/fpdf_page.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698