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

Side by Side Diff: pdf/pdfium/pdfium_engine.cc

Issue 2248873002: Convert WindowOpenDisposition to an enum class. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase. Created 4 years, 3 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 | « pdf/out_of_process_instance.cc ('k') | services/navigation/view_impl.cc » ('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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium 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 #include "pdf/pdfium/pdfium_engine.h" 5 #include "pdf/pdfium/pdfium_engine.h"
6 6
7 #include <math.h> 7 #include <math.h>
8 #include <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 10
(...skipping 3539 matching lines...) Expand 10 before | Expand all | Expand 10 after
3550 FPDF_WIDESTRING value, 3550 FPDF_WIDESTRING value,
3551 FPDF_DWORD valueLen, 3551 FPDF_DWORD valueLen,
3552 FPDF_BOOL is_focus) { 3552 FPDF_BOOL is_focus) {
3553 // Do nothing for now. 3553 // Do nothing for now.
3554 // TODO(gene): use this signal to trigger OSK. 3554 // TODO(gene): use this signal to trigger OSK.
3555 } 3555 }
3556 3556
3557 void PDFiumEngine::Form_DoURIAction(FPDF_FORMFILLINFO* param, 3557 void PDFiumEngine::Form_DoURIAction(FPDF_FORMFILLINFO* param,
3558 FPDF_BYTESTRING uri) { 3558 FPDF_BYTESTRING uri) {
3559 PDFiumEngine* engine = static_cast<PDFiumEngine*>(param); 3559 PDFiumEngine* engine = static_cast<PDFiumEngine*>(param);
3560 engine->client_->NavigateTo(std::string(uri), CURRENT_TAB); 3560 engine->client_->NavigateTo(std::string(uri),
3561 WindowOpenDisposition::CURRENT_TAB);
3561 } 3562 }
3562 3563
3563 void PDFiumEngine::Form_DoGoToAction(FPDF_FORMFILLINFO* param, 3564 void PDFiumEngine::Form_DoGoToAction(FPDF_FORMFILLINFO* param,
3564 int page_index, 3565 int page_index,
3565 int zoom_mode, 3566 int zoom_mode,
3566 float* position_array, 3567 float* position_array,
3567 int size_of_array) { 3568 int size_of_array) {
3568 PDFiumEngine* engine = static_cast<PDFiumEngine*>(param); 3569 PDFiumEngine* engine = static_cast<PDFiumEngine*>(param);
3569 engine->ScrollToPage(page_index); 3570 engine->ScrollToPage(page_index);
3570 } 3571 }
(...skipping 400 matching lines...) Expand 10 before | Expand all | Expand 10 after
3971 FPDF_DOCUMENT doc = 3972 FPDF_DOCUMENT doc =
3972 FPDF_LoadMemDocument(pdf_buffer, pdf_buffer_size, nullptr); 3973 FPDF_LoadMemDocument(pdf_buffer, pdf_buffer_size, nullptr);
3973 if (!doc) 3974 if (!doc)
3974 return false; 3975 return false;
3975 bool success = FPDF_GetPageSizeByIndex(doc, page_number, width, height) != 0; 3976 bool success = FPDF_GetPageSizeByIndex(doc, page_number, width, height) != 0;
3976 FPDF_CloseDocument(doc); 3977 FPDF_CloseDocument(doc);
3977 return success; 3978 return success;
3978 } 3979 }
3979 3980
3980 } // namespace chrome_pdf 3981 } // namespace chrome_pdf
OLDNEW
« no previous file with comments | « pdf/out_of_process_instance.cc ('k') | services/navigation/view_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698