Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 113e3fda authored by Svet Ganov's avatar Svet Ganov Committed by Android Git Automerger
Browse files

am e0748316: Merge "Update the pdfium library - framework" into mnc-dev

* commit 'e0748316':
  Update the pdfium library - framework
parents d3f321e6 e0748316
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -183,6 +183,7 @@ LOCAL_C_INCLUDES += \
    external/pdfium/core/include/fpdfapi \
    external/pdfium/core/include/fpdfdoc \
    external/pdfium/fpdfsdk/include \
    external/pdfium/public \
    external/skia/src/core \
    external/skia/src/effects \
    external/skia/src/images \
+3 −3
Original line number Diff line number Diff line
@@ -20,8 +20,8 @@
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wdelete-non-virtual-dtor"
#include "fpdfview.h"
#include "fpdfedit.h"
#include "fpdfsave.h"
#include "fpdf_edit.h"
#include "fpdf_save.h"
#include "fsdk_rendercontext.h"
#include "fpdf_transformpage.h"
#pragma GCC diagnostic pop
@@ -58,7 +58,7 @@ static int sUnmatchedInitRequestCount = 0;
static void initializeLibraryIfNeeded() {
    Mutex::Autolock _l(sLock);
    if (sUnmatchedInitRequestCount == 0) {
        FPDF_InitLibrary(NULL);
        FPDF_InitLibrary();
    }
    sUnmatchedInitRequestCount++;
}
+6 −6
Original line number Diff line number Diff line
@@ -50,7 +50,7 @@ static int sUnmatchedInitRequestCount = 0;
static void initializeLibraryIfNeeded() {
    Mutex::Autolock _l(sLock);
    if (sUnmatchedInitRequestCount == 0) {
        FPDF_InitLibrary(NULL);
        FPDF_InitLibrary();
    }
    sUnmatchedInitRequestCount++;
}
@@ -165,12 +165,12 @@ static void renderPageBitmap(FPDF_BITMAP bitmap, FPDF_PAGE page, int destLeft, i
    // and FPDF_ANNOT flags. To add support for that refer to FPDF_RenderPage_Retail
    // in fpdfview.cpp

    CRenderContext* pContext = FX_NEW CRenderContext;
    CRenderContext* pContext = new CRenderContext;

    CPDF_Page* pPage = (CPDF_Page*) page;
    pPage->SetPrivateData((void*) 1, pContext, DropContext);

    CFX_FxgeDevice* fxgeDevice = FX_NEW CFX_FxgeDevice;
    CFX_FxgeDevice* fxgeDevice = new CFX_FxgeDevice;
    pContext->m_pDevice = fxgeDevice;

    // Reverse the bytes (last argument TRUE) since the Android
@@ -180,7 +180,7 @@ static void renderPageBitmap(FPDF_BITMAP bitmap, FPDF_PAGE page, int destLeft, i
    CPDF_RenderOptions* renderOptions = pContext->m_pOptions;

    if (!renderOptions) {
        renderOptions = FX_NEW CPDF_RenderOptions;
        renderOptions = new CPDF_RenderOptions;
        pContext->m_pOptions = renderOptions;
    }

@@ -205,7 +205,7 @@ static void renderPageBitmap(FPDF_BITMAP bitmap, FPDF_PAGE page, int destLeft, i
    clip.bottom = destBottom;
    fxgeDevice->SetClip_Rect(&clip);

    CPDF_RenderContext* pageContext = FX_NEW CPDF_RenderContext;
    CPDF_RenderContext* pageContext = new CPDF_RenderContext;
    pContext->m_pContext = pageContext;
    pageContext->Create(pPage);

@@ -232,7 +232,7 @@ static void renderPageBitmap(FPDF_BITMAP bitmap, FPDF_PAGE page, int destLeft, i
    }
    pageContext->AppendObjectList(pPage, &matrix);

    pContext->m_pRenderer = FX_NEW CPDF_ProgressiveRenderer;
    pContext->m_pRenderer = new CPDF_ProgressiveRenderer;
    pContext->m_pRenderer->Start(pageContext, fxgeDevice, renderOptions, NULL);

    fxgeDevice->RestoreState();