summaryrefslogtreecommitdiff
path: root/core/fpdfapi/page/cpdf_pageobjectholder.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'core/fpdfapi/page/cpdf_pageobjectholder.cpp')
-rw-r--r--core/fpdfapi/page/cpdf_pageobjectholder.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/core/fpdfapi/page/cpdf_pageobjectholder.cpp b/core/fpdfapi/page/cpdf_pageobjectholder.cpp
index 3eb88ec9c0..67f68c7c42 100644
--- a/core/fpdfapi/page/cpdf_pageobjectholder.cpp
+++ b/core/fpdfapi/page/cpdf_pageobjectholder.cpp
@@ -15,6 +15,21 @@
#include "core/fpdfapi/page/cpdf_pageobject.h"
#include "core/fpdfapi/parser/cpdf_dictionary.h"
#include "core/fpdfapi/parser/cpdf_document.h"
+#include "core/fxcrt/fx_extension.h"
+
+bool GraphicsData::operator<(const GraphicsData& other) const {
+ if (!FXSYS_SafeEQ(fillAlpha, other.fillAlpha))
+ return FXSYS_SafeLT(fillAlpha, other.fillAlpha);
+ if (!FXSYS_SafeEQ(strokeAlpha, other.strokeAlpha))
+ return FXSYS_SafeLT(strokeAlpha, other.strokeAlpha);
+ return blendType < other.blendType;
+}
+
+bool FontData::operator<(const FontData& other) const {
+ if (baseFont != other.baseFont)
+ return baseFont < other.baseFont;
+ return type < other.type;
+}
CPDF_PageObjectHolder::CPDF_PageObjectHolder(CPDF_Document* pDoc,
CPDF_Dictionary* pDict)