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

Unified Diff: core/src/fpdfapi/fpdf_page/fpdf_page_func.cpp

Issue 1292613003: Use override in more classes in core/ (Closed) Base URL: https://pdfium.googlesource.com/pdfium@master
Patch Set: nit Created 5 years, 4 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 | « core/src/fpdfapi/fpdf_font/ttgsubtable.h ('k') | core/src/fpdfapi/fpdf_parser/fpdf_parser_parser.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: core/src/fpdfapi/fpdf_page/fpdf_page_func.cpp
diff --git a/core/src/fpdfapi/fpdf_page/fpdf_page_func.cpp b/core/src/fpdfapi/fpdf_page/fpdf_page_func.cpp
index 87ff0a3b634a209074cd22d70f367120446f0c57..1ee062ee7c72f42586bbf5b07a3960ed0269983d 100644
--- a/core/src/fpdfapi/fpdf_page/fpdf_page_func.cpp
+++ b/core/src/fpdfapi/fpdf_page/fpdf_page_func.cpp
@@ -463,18 +463,23 @@ typedef struct {
int sizes;
} SampleEncodeInfo;
typedef struct { FX_FLOAT decode_max, decode_min; } SampleDecodeInfo;
+
class CPDF_SampledFunc : public CPDF_Function {
public:
CPDF_SampledFunc();
- virtual ~CPDF_SampledFunc();
- virtual FX_BOOL v_Init(CPDF_Object* pObj);
- virtual FX_BOOL v_Call(FX_FLOAT* inputs, FX_FLOAT* results) const;
+ ~CPDF_SampledFunc() override;
+
+ // CPDF_Function
+ FX_BOOL v_Init(CPDF_Object* pObj) override;
+ FX_BOOL v_Call(FX_FLOAT* inputs, FX_FLOAT* results) const override;
+
SampleEncodeInfo* m_pEncodeInfo;
SampleDecodeInfo* m_pDecodeInfo;
FX_DWORD m_nBitsPerSample;
FX_DWORD m_SampleMax;
CPDF_StreamAcc* m_pSampleStream;
};
+
CPDF_SampledFunc::CPDF_SampledFunc() {
m_pSampleStream = NULL;
m_pEncodeInfo = NULL;
@@ -620,12 +625,16 @@ FX_BOOL CPDF_SampledFunc::v_Call(FX_FLOAT* inputs, FX_FLOAT* results) const {
}
return TRUE;
}
+
class CPDF_PSFunc : public CPDF_Function {
public:
- virtual FX_BOOL v_Init(CPDF_Object* pObj);
- virtual FX_BOOL v_Call(FX_FLOAT* inputs, FX_FLOAT* results) const;
+ // CPDF_Function
+ FX_BOOL v_Init(CPDF_Object* pObj) override;
+ FX_BOOL v_Call(FX_FLOAT* inputs, FX_FLOAT* results) const override;
+
CPDF_PSEngine m_PS;
};
+
FX_BOOL CPDF_PSFunc::v_Init(CPDF_Object* pObj) {
CPDF_Stream* pStream = (CPDF_Stream*)pObj;
CPDF_StreamAcc acc;
@@ -648,17 +657,22 @@ FX_BOOL CPDF_PSFunc::v_Call(FX_FLOAT* inputs, FX_FLOAT* results) const {
}
return TRUE;
}
+
class CPDF_ExpIntFunc : public CPDF_Function {
public:
CPDF_ExpIntFunc();
- virtual ~CPDF_ExpIntFunc();
- virtual FX_BOOL v_Init(CPDF_Object* pObj);
- virtual FX_BOOL v_Call(FX_FLOAT* inputs, FX_FLOAT* results) const;
+ ~CPDF_ExpIntFunc() override;
+
+ // CPDF_Function
+ FX_BOOL v_Init(CPDF_Object* pObj) override;
+ FX_BOOL v_Call(FX_FLOAT* inputs, FX_FLOAT* results) const override;
+
FX_FLOAT m_Exponent;
FX_FLOAT* m_pBeginValues;
FX_FLOAT* m_pEndValues;
int m_nOrigOutputs;
};
+
CPDF_ExpIntFunc::CPDF_ExpIntFunc() {
m_pBeginValues = NULL;
m_pEndValues = NULL;
@@ -708,17 +722,22 @@ FX_BOOL CPDF_ExpIntFunc::v_Call(FX_FLOAT* inputs, FX_FLOAT* results) const {
}
return TRUE;
}
+
class CPDF_StitchFunc : public CPDF_Function {
public:
CPDF_StitchFunc();
- virtual ~CPDF_StitchFunc();
- virtual FX_BOOL v_Init(CPDF_Object* pObj);
- virtual FX_BOOL v_Call(FX_FLOAT* inputs, FX_FLOAT* results) const;
+ ~CPDF_StitchFunc() override;
+
+ // CPDF_Function
+ FX_BOOL v_Init(CPDF_Object* pObj) override;
+ FX_BOOL v_Call(FX_FLOAT* inputs, FX_FLOAT* results) const override;
+
int m_nSubs;
CPDF_Function** m_pSubFunctions;
FX_FLOAT* m_pBounds;
FX_FLOAT* m_pEncode;
};
+
CPDF_StitchFunc::CPDF_StitchFunc() {
m_nSubs = 0;
m_pSubFunctions = NULL;
« no previous file with comments | « core/src/fpdfapi/fpdf_font/ttgsubtable.h ('k') | core/src/fpdfapi/fpdf_parser/fpdf_parser_parser.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698