summaryrefslogtreecommitdiff
path: root/core/fxcodec/codec
diff options
context:
space:
mode:
authorDan Sinclair <dsinclair@chromium.org>2017-05-04 12:12:06 -0400
committerChromium commit bot <commit-bot@chromium.org>2017-05-04 16:48:35 +0000
commitdcefccc9f0f2002f79a4a67048fac1360c1d6c26 (patch)
tree0b337a17f590d544ec2f20c5645cdb62b0b4c8b8 /core/fxcodec/codec
parentdf673c28191cca181ef526d02f24b4a7a6f5e200 (diff)
downloadpdfium-dcefccc9f0f2002f79a4a67048fac1360c1d6c26.tar.xz
Removing unused IFX_Pause parameters
Remove more IFX_Pause parameters which are not used. Change-Id: I9d10bb6b28d6d4d94ec3c4241b1c5a8a0709264c Reviewed-on: https://pdfium-review.googlesource.com/4875 Reviewed-by: Nicolás Peña <npm@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
Diffstat (limited to 'core/fxcodec/codec')
-rw-r--r--core/fxcodec/codec/ccodec_progressivedecoder.h5
-rw-r--r--core/fxcodec/codec/fx_codec_progress.cpp29
2 files changed, 6 insertions, 28 deletions
diff --git a/core/fxcodec/codec/ccodec_progressivedecoder.h b/core/fxcodec/codec/ccodec_progressivedecoder.h
index 6081fe3c19..f63c1ded0c 100644
--- a/core/fxcodec/codec/ccodec_progressivedecoder.h
+++ b/core/fxcodec/codec/ccodec_progressivedecoder.h
@@ -22,7 +22,6 @@ class CCodec_JpegModule;
class CCodec_ModuleMgr;
class CFX_DIBAttribute;
class IFX_SeekableReadStream;
-class IFX_Pause;
struct FXJPEG_Context;
class CCodec_ProgressiveDecoder : public CCodec_BmpModule::Delegate,
@@ -57,7 +56,7 @@ class CCodec_ProgressiveDecoder : public CCodec_BmpModule::Delegate,
int32_t GetBPC() const { return m_SrcBPC; }
void SetClipBox(FX_RECT* clip);
- FXCODEC_STATUS GetFrames(int32_t& frames, IFX_Pause* pPause = nullptr);
+ FXCODEC_STATUS GetFrames(int32_t& frames);
FXCODEC_STATUS StartDecode(const CFX_RetainPtr<CFX_DIBitmap>& pDIBitmap,
int start_x,
int start_y,
@@ -66,7 +65,7 @@ class CCodec_ProgressiveDecoder : public CCodec_BmpModule::Delegate,
int32_t frames = 0,
bool bInterpol = true);
- FXCODEC_STATUS ContinueDecode(IFX_Pause* pPause = nullptr);
+ FXCODEC_STATUS ContinueDecode();
struct PixelWeight {
int m_SrcStart;
diff --git a/core/fxcodec/codec/fx_codec_progress.cpp b/core/fxcodec/codec/fx_codec_progress.cpp
index 9d710e582d..e26431ffab 100644
--- a/core/fxcodec/codec/fx_codec_progress.cpp
+++ b/core/fxcodec/codec/fx_codec_progress.cpp
@@ -1784,8 +1784,7 @@ void CCodec_ProgressiveDecoder::Resample(
}
}
-FXCODEC_STATUS CCodec_ProgressiveDecoder::GetFrames(int32_t& frames,
- IFX_Pause* pPause) {
+FXCODEC_STATUS CCodec_ProgressiveDecoder::GetFrames(int32_t& frames) {
if (!(m_status == FXCODEC_STATUS_FRAME_READY ||
m_status == FXCODEC_STATUS_FRAME_TOBECONTINUE)) {
return FXCODEC_STATUS_ERROR;
@@ -1809,13 +1808,9 @@ FXCODEC_STATUS CCodec_ProgressiveDecoder::GetFrames(int32_t& frames,
pGifModule->LoadFrameInfo(m_pGifContext, &m_FrameNumber);
while (readResult == GifDecodeStatus::Unfinished) {
FXCODEC_STATUS error_status = FXCODEC_STATUS_ERR_READ;
- if (!GifReadMoreData(pGifModule, error_status)) {
+ if (!GifReadMoreData(pGifModule, error_status))
return error_status;
- }
- if (pPause && pPause->NeedToPauseNow()) {
- m_status = FXCODEC_STATUS_FRAME_TOBECONTINUE;
- return m_status;
- }
+
readResult = pGifModule->LoadFrameInfo(m_pGifContext, &m_FrameNumber);
}
if (readResult == GifDecodeStatus::Success) {
@@ -2043,7 +2038,7 @@ FXCODEC_STATUS CCodec_ProgressiveDecoder::StartDecode(
}
}
-FXCODEC_STATUS CCodec_ProgressiveDecoder::ContinueDecode(IFX_Pause* pPause) {
+FXCODEC_STATUS CCodec_ProgressiveDecoder::ContinueDecode() {
if (m_status != FXCODEC_STATUS_DECODE_TOBECONTINUE)
return FXCODEC_STATUS_ERROR;
@@ -2074,10 +2069,6 @@ FXCODEC_STATUS CCodec_ProgressiveDecoder::ContinueDecode(IFX_Pause* pPause) {
}
Resample(m_pDeviceBitmap, m_SrcRow, m_pDecodeBuf, m_SrcFormat);
m_SrcRow++;
- if (pPause && pPause->NeedToPauseNow()) {
- m_status = FXCODEC_STATUS_DECODE_TOBECONTINUE;
- return m_status;
- }
}
}
case FXCODEC_IMAGE_PNG: {
@@ -2122,10 +2113,6 @@ FXCODEC_STATUS CCodec_ProgressiveDecoder::ContinueDecode(IFX_Pause* pPause) {
m_status = FXCODEC_STATUS_ERROR;
return m_status;
}
- if (pPause && pPause->NeedToPauseNow()) {
- m_status = FXCODEC_STATUS_DECODE_TOBECONTINUE;
- return m_status;
- }
}
}
case FXCODEC_IMAGE_GIF: {
@@ -2145,10 +2132,6 @@ FXCODEC_STATUS CCodec_ProgressiveDecoder::ContinueDecode(IFX_Pause* pPause) {
m_status = error_status;
return m_status;
}
- if (pPause && pPause->NeedToPauseNow()) {
- m_status = FXCODEC_STATUS_DECODE_TOBECONTINUE;
- return m_status;
- }
readRes = pGifModule->LoadFrame(m_pGifContext, m_FrameCur, nullptr);
}
if (readRes == GifDecodeStatus::Success) {
@@ -2179,10 +2162,6 @@ FXCODEC_STATUS CCodec_ProgressiveDecoder::ContinueDecode(IFX_Pause* pPause) {
m_status = error_status;
return m_status;
}
- if (pPause && pPause->NeedToPauseNow()) {
- m_status = FXCODEC_STATUS_DECODE_TOBECONTINUE;
- return m_status;
- }
readRes = pBmpModule->LoadImage(m_pBmpContext);
}
if (readRes == 1) {