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

Unified Diff: pdf/out_of_process_instance.cc

Issue 2166193002: Handle ctrl + shift + left click on links in PDF. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Handle ctrl + shift + left click on links in PDF. Created 4 years, 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « pdf/out_of_process_instance.h ('k') | pdf/pdf_engine.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pdf/out_of_process_instance.cc
diff --git a/pdf/out_of_process_instance.cc b/pdf/out_of_process_instance.cc
index 6cce626dd822537f84bf67860878cea2878edb45..1444620c65aec081208bbf33b80531c5cf195118 100644
--- a/pdf/out_of_process_instance.cc
+++ b/pdf/out_of_process_instance.cc
@@ -104,7 +104,7 @@ const char kJSCancelStreamUrlType[] = "cancelStreamUrl";
// Navigate to the given URL (Plugin -> Page)
const char kJSNavigateType[] = "navigate";
const char kJSNavigateUrl[] = "url";
-const char kJSNavigateNewTab[] = "newTab";
+const char kJSNavigateOption[] = "option";
// Open the email editor with the given parameters (Plugin -> Page)
const char kJSEmailType[] = "email";
const char kJSEmailTo[] = "to";
@@ -976,12 +976,13 @@ void OutOfProcessInstance::ScrollToPage(int page) {
PostMessage(message);
}
-void OutOfProcessInstance::NavigateTo(const std::string& url,
- bool open_in_new_tab) {
+void OutOfProcessInstance::NavigateTo(
+ const std::string& url,
+ PDFEngine::Client::NavigateOption option) {
pp::VarDictionary message;
message.Set(kType, kJSNavigateType);
message.Set(kJSNavigateUrl, url);
- message.Set(kJSNavigateNewTab, open_in_new_tab);
+ message.Set(kJSNavigateOption, pp::Var(static_cast<int>(option)));
jaepark 2016/07/21 22:34:33 To pass enum class from Plugin to Page, I used sta
PostMessage(message);
}
« no previous file with comments | « pdf/out_of_process_instance.h ('k') | pdf/pdf_engine.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698