Enable noshadowing in pdf/
Rename shadowed variables in PDFiumPage::GetLinkTarget() Bug: 993548 Change-Id: I88e660b6df99c4f3e2140014e1bb5e6626d56ddc Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1893504 Commit-Queue: Daniel Hosseinian <dhoss@chromium.org> Reviewed-by: Lei Zhang <thestig@chromium.org> Cr-Commit-Position: refs/heads/master@{#711589}
This commit is contained in:

committed by
Commit Bot

parent
7793d41b38
commit
919ab0d6e4
pdf
@ -20,6 +20,8 @@ if (enable_pdf) {
|
|||||||
pdf_engine = 0 # 0 PDFium
|
pdf_engine = 0 # 0 PDFium
|
||||||
|
|
||||||
config("pdf_common_config") {
|
config("pdf_common_config") {
|
||||||
|
configs = [ "//build/config/compiler:noshadowing" ]
|
||||||
|
|
||||||
if (pdf_engine == 0) {
|
if (pdf_engine == 0) {
|
||||||
include_dirs = [ "//third_party/pdfium" ]
|
include_dirs = [ "//third_party/pdfium" ]
|
||||||
}
|
}
|
||||||
@ -155,6 +157,8 @@ if (enable_pdf) {
|
|||||||
"test/test_utils.h",
|
"test/test_utils.h",
|
||||||
]
|
]
|
||||||
|
|
||||||
|
configs += [ "//build/config/compiler:noshadowing" ]
|
||||||
|
|
||||||
deps = [
|
deps = [
|
||||||
":pdf",
|
":pdf",
|
||||||
"//base",
|
"//base",
|
||||||
|
@ -660,9 +660,9 @@ int PDFiumPage::GetCharCount() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
PDFiumPage::Area PDFiumPage::GetLinkTarget(FPDF_LINK link, LinkTarget* target) {
|
PDFiumPage::Area PDFiumPage::GetLinkTarget(FPDF_LINK link, LinkTarget* target) {
|
||||||
FPDF_DEST dest = FPDFLink_GetDest(engine_->doc(), link);
|
FPDF_DEST dest_link = FPDFLink_GetDest(engine_->doc(), link);
|
||||||
if (dest)
|
if (dest_link)
|
||||||
return GetDestinationTarget(dest, target);
|
return GetDestinationTarget(dest_link, target);
|
||||||
|
|
||||||
FPDF_ACTION action = FPDFLink_GetAction(link);
|
FPDF_ACTION action = FPDFLink_GetAction(link);
|
||||||
if (!action)
|
if (!action)
|
||||||
@ -670,9 +670,9 @@ PDFiumPage::Area PDFiumPage::GetLinkTarget(FPDF_LINK link, LinkTarget* target) {
|
|||||||
|
|
||||||
switch (FPDFAction_GetType(action)) {
|
switch (FPDFAction_GetType(action)) {
|
||||||
case PDFACTION_GOTO: {
|
case PDFACTION_GOTO: {
|
||||||
FPDF_DEST dest = FPDFAction_GetDest(engine_->doc(), action);
|
FPDF_DEST dest_action = FPDFAction_GetDest(engine_->doc(), action);
|
||||||
if (dest)
|
if (dest_action)
|
||||||
return GetDestinationTarget(dest, target);
|
return GetDestinationTarget(dest_action, target);
|
||||||
// TODO(crbug.com/55776): We don't fully support all types of the
|
// TODO(crbug.com/55776): We don't fully support all types of the
|
||||||
// in-document links.
|
// in-document links.
|
||||||
return NONSELECTABLE_AREA;
|
return NONSELECTABLE_AREA;
|
||||||
|
Reference in New Issue
Block a user