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

Side by Side Diff: core/src/fpdfapi/fpdf_edit/fpdf_edit_doc.cpp

Issue 1747123002: Fix and enable lint checks. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Created 4 years, 9 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 unified diff | Download patch
« no previous file with comments | « core/include/fxcrt/fx_memory.h ('k') | core/src/fpdfapi/fpdf_font/font_int.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 PDFium Authors. All rights reserved. 1 // Copyright 2014 PDFium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
6 6
7 #include <limits.h> 7 #include <limits.h>
8 8
9 #include "core/include/fpdfapi/fpdf_module.h" 9 #include "core/include/fpdfapi/fpdf_module.h"
10 #include "core/include/fpdfapi/fpdf_page.h" 10 #include "core/include/fpdfapi/fpdf_page.h"
(...skipping 454 matching lines...) Expand 10 before | Expand all | Expand 10 after
465 int32_t iMid = (iStart + iEnd) / 2; 465 int32_t iMid = (iStart + iEnd) / 2;
466 const FX_LANG2CS& charset = gs_FXLang2CharsetTable[iMid]; 466 const FX_LANG2CS& charset = gs_FXLang2CharsetTable[iMid];
467 if (uCode == charset.uLang) { 467 if (uCode == charset.uLang) {
468 return charset.uCharset; 468 return charset.uCharset;
469 } 469 }
470 if (uCode < charset.uLang) { 470 if (uCode < charset.uLang) {
471 iEnd = iMid - 1; 471 iEnd = iMid - 1;
472 } else { 472 } else {
473 iStart = iMid + 1; 473 iStart = iMid + 1;
474 } 474 }
475 }; 475 }
476 return 0; 476 return 0;
477 } 477 }
478 static FX_WORD FX_GetCharsetFromLang(const FX_CHAR* pLang, int32_t iLength) { 478 static FX_WORD FX_GetCharsetFromLang(const FX_CHAR* pLang, int32_t iLength) {
479 FXSYS_assert(pLang); 479 FXSYS_assert(pLang);
480 if (iLength < 0) { 480 if (iLength < 0) {
481 iLength = FXSYS_strlen(pLang); 481 iLength = FXSYS_strlen(pLang);
482 } 482 }
483 uint32_t uHash = FX_GetLangHashCode(pLang); 483 uint32_t uHash = FX_GetLangHashCode(pLang);
484 return FX_GetCsFromLangCode(uHash); 484 return FX_GetCsFromLangCode(uHash);
485 } 485 }
(...skipping 655 matching lines...) Expand 10 before | Expand all | Expand 10 after
1141 void FPDFAPI_FlatPageAttr(CPDF_Dictionary* pPageDict, 1141 void FPDFAPI_FlatPageAttr(CPDF_Dictionary* pPageDict,
1142 const CFX_ByteStringC& name) { 1142 const CFX_ByteStringC& name) {
1143 if (pPageDict->KeyExist(name)) { 1143 if (pPageDict->KeyExist(name)) {
1144 return; 1144 return;
1145 } 1145 }
1146 CPDF_Object* pObj = FPDFAPI_GetPageAttr(pPageDict, name); 1146 CPDF_Object* pObj = FPDFAPI_GetPageAttr(pPageDict, name);
1147 if (pObj) { 1147 if (pObj) {
1148 pPageDict->SetAt(name, pObj->Clone()); 1148 pPageDict->SetAt(name, pObj->Clone());
1149 } 1149 }
1150 } 1150 }
OLDNEW
« no previous file with comments | « core/include/fxcrt/fx_memory.h ('k') | core/src/fpdfapi/fpdf_font/font_int.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698