diff options
author | Nico Weber <thakis@chromium.org> | 2015-08-06 14:38:03 -0700 |
---|---|---|
committer | Nico Weber <thakis@chromium.org> | 2015-08-06 14:38:03 -0700 |
commit | 4684c83a4e9114a63c64744064dd190e4d459c6f (patch) | |
tree | e34d3d36735db7d1692d1da95aa732f3241d9906 /fpdfsdk/src | |
parent | 905cc10ecd06bcacfefb747cc3370c72772f0e15 (diff) | |
download | pdfium-4684c83a4e9114a63c64744064dd190e4d459c6f.tar.xz |
clang-format all pdfium code, again.
Also add a presubmit that checks for this so I don't have to keep doing it.
No behavior change.
Generated by:
find . -name '*.cpp' -o -name '*.h' | \
grep -E -v 'third_party|thirdparties|lpng_v163' | \
xargs ../../buildtools/mac/clang-format -i
BUG=none
R=thestig@chromium.org
Review URL: https://codereview.chromium.org/1272653005 .
Diffstat (limited to 'fpdfsdk/src')
-rw-r--r-- | fpdfsdk/src/fpdfview.cpp | 1 | ||||
-rw-r--r-- | fpdfsdk/src/fsdk_baseform.cpp | 17 | ||||
-rw-r--r-- | fpdfsdk/src/fxedit/fxet_ap.cpp | 5 | ||||
-rw-r--r-- | fpdfsdk/src/javascript/app.cpp | 4 | ||||
-rw-r--r-- | fpdfsdk/src/pdfwindow/PWL_ListBox.cpp | 2 |
5 files changed, 5 insertions, 24 deletions
diff --git a/fpdfsdk/src/fpdfview.cpp b/fpdfsdk/src/fpdfview.cpp index 8895dce076..9ad3384803 100644 --- a/fpdfsdk/src/fpdfview.cpp +++ b/fpdfsdk/src/fpdfview.cpp @@ -155,7 +155,6 @@ DLLEXPORT void STDCALL FPDF_SetSandBoxPolicy(FPDF_DWORD policy, return FSDK_SetSandBoxPolicy(policy, enable); } - DLLEXPORT FPDF_DOCUMENT STDCALL FPDF_LoadDocument(FPDF_STRING file_path, FPDF_BYTESTRING password) { // NOTE: the creation of the file needs to be by the embedder on the diff --git a/fpdfsdk/src/fsdk_baseform.cpp b/fpdfsdk/src/fsdk_baseform.cpp index bc041fd05f..ca0c29efa4 100644 --- a/fpdfsdk/src/fsdk_baseform.cpp +++ b/fpdfsdk/src/fsdk_baseform.cpp @@ -396,8 +396,6 @@ void CPDFSDK_Widget::DrawShadow(CFX_RenderDevice* pDevice, int nFieldType = GetFieldType(); if (m_pInterForm->IsNeedHighLight(nFieldType)) { - // if (nFieldType != FIELDTYPE_PUSHBUTTON) - // { CPDF_Rect rc = GetRect(); FX_COLORREF color = m_pInterForm->GetHighlightColor(nFieldType); uint8_t alpha = m_pInterForm->GetHighlightAlpha(); @@ -411,10 +409,6 @@ void CPDFSDK_Widget::DrawShadow(CFX_RenderDevice* pDevice, pPageView->GetCurrentMatrix(page2device); page2device.Transform(((FX_FLOAT)rc.left), ((FX_FLOAT)rc.bottom), rcDevice.left, rcDevice.bottom); - // pEnv->FFI_PageToDevice(m_pPageView->GetPDFPage(), rc.left, - // rc.bottom, &rcDevice.left, &rcDevice.bottom); - // pEnv->FFI_PageToDevice(m_pPageView->GetPDFPage(), rc.right, - // rc.top, &rcDevice.right, &rcDevice.top); page2device.Transform(((FX_FLOAT)rc.right), ((FX_FLOAT)rc.top), rcDevice.right, rcDevice.top); @@ -424,7 +418,6 @@ void CPDFSDK_Widget::DrawShadow(CFX_RenderDevice* pDevice, FX_RECT rcDev((int)rcDevice.left, (int)rcDevice.top, (int)rcDevice.right, (int)rcDevice.bottom); pDevice->FillRect(&rcDev, argb); - /* }*/ } } @@ -573,10 +566,7 @@ void CPDFSDK_Widget::ResetAppearance_PushButton() { ASSERT(pDoc != NULL); CPDFDoc_Environment* pEnv = pDoc->GetEnv(); - CBA_FontMap FontMap( - this, - pEnv->GetSysHandler()); //, - //ISystemHandle::GetSystemHandler(m_pBaseForm->GetEnv())); + CBA_FontMap FontMap(this, pEnv->GetSysHandler()); FontMap.Initial(); FontMap.SetAPType("N"); @@ -1136,10 +1126,7 @@ void CPDFSDK_Widget::ResetAppearance_TextField(const FX_WCHAR* sValue) { ASSERT(pDoc != NULL); CPDFDoc_Environment* pEnv = pDoc->GetEnv(); - CBA_FontMap FontMap( - this, - pEnv->GetSysHandler()); //, - //ISystemHandle::GetSystemHandler(m_pBaseForm->GetEnv())); + CBA_FontMap FontMap(this, pEnv->GetSysHandler()); FontMap.Initial(); pEdit->SetFontMap(&FontMap); diff --git a/fpdfsdk/src/fxedit/fxet_ap.cpp b/fpdfsdk/src/fxedit/fxet_ap.cpp index b9900d899b..4e92099417 100644 --- a/fpdfsdk/src/fxedit/fxet_ap.cpp +++ b/fpdfsdk/src/fxedit/fxet_ap.cpp @@ -196,11 +196,6 @@ CFX_ByteString IFX_Edit::GetSelectAppearanceStream( CPVT_Word word; CPVT_Line line; if (pIterator->GetWord(word) && pIterator->GetLine(line)) { - // CPDF_Rect rcWordSel = CPDF_Rect(word.ptWord.x,line.ptLine.y + - // line.fLineDescent, - // word.ptWord.x+word.fWidth,line.ptLine.y + - //line.fLineAscent); - sRet << word.ptWord.x + ptOffset.x << " " << line.ptLine.y + line.fLineDescent << " " << word.fWidth << " " << line.fLineAscent - line.fLineDescent << " re\nf\n"; diff --git a/fpdfsdk/src/javascript/app.cpp b/fpdfsdk/src/javascript/app.cpp index 29007a4a2a..24f00ca262 100644 --- a/fpdfsdk/src/javascript/app.cpp +++ b/fpdfsdk/src/javascript/app.cpp @@ -302,10 +302,10 @@ FX_BOOL app::alert(IFXJS_Context* cc, CJS_Value* pValue = new CJS_Value(isolate); // if (iLenth == 1) // pValue = new - //CJS_Value(isolate); + // CJS_Value(isolate); // else if (iLenth > 1) // pValue = new - //CJS_Value[iLenth]; + // CJS_Value[iLenth]; for (int i = 0; i < iLenth; i++) { carray.GetElement(i, *pValue); diff --git a/fpdfsdk/src/pdfwindow/PWL_ListBox.cpp b/fpdfsdk/src/pdfwindow/PWL_ListBox.cpp index ba75e55fdf..b252bffb8e 100644 --- a/fpdfsdk/src/pdfwindow/PWL_ListBox.cpp +++ b/fpdfsdk/src/pdfwindow/PWL_ListBox.cpp @@ -183,7 +183,7 @@ void CPWL_ListBox::DrawThisAppearance(CFX_RenderDevice* pDevice, if (m_pList->IsItemSelected(i)) { // CPWL_Utils::DrawFillRect(pDevice, pUser2Device, rcItem, - //ArgbEncode(255,0,51,113)); + // ArgbEncode(255,0,51,113)); IFX_SystemHandler* pSysHandler = GetSystemHandler(); if (pSysHandler && pSysHandler->IsSelectionImplemented()) { IFX_Edit::DrawEdit( |