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

Unified Diff: pdf/out_of_process_instance.cc

Issue 814573004: Fix for Multipage selection by dragging mouse in OOP case in PDF. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressing nit. Created 5 years, 10 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
Index: pdf/out_of_process_instance.cc
diff --git a/pdf/out_of_process_instance.cc b/pdf/out_of_process_instance.cc
index 0ccfa36b5db64281b17a92f000f21c6d206e77f7..47d442fe4fd3dbe44fba9af455e727a0afa6381f 100644
--- a/pdf/out_of_process_instance.cc
+++ b/pdf/out_of_process_instance.cc
@@ -144,6 +144,10 @@ const char kJSSelectedText[] = "selectedText";
const char kJSSetNamedDestinationsType[] = "setNamedDestinations";
const char kJSNamedDestinations[] = "namedDestinations";
+// Selecting text in document (Plugin -> Page)
+const char kJSSetIsSelectingType[] = "setIsSelecting";
+const char kJSIsSelecting[] = "isSelecting";
+
const int kFindResultCooldownMs = 100;
const double kMinZoom = 0.01;
@@ -1347,6 +1351,13 @@ bool OutOfProcessInstance::IsPrintPreview() {
return IsPrintPreviewUrl(url_);
}
+void OutOfProcessInstance::IsSelectingChanged(bool is_selecting) {
+ pp::VarDictionary message;
+ message.Set(kType, kJSSetIsSelectingType);
+ message.Set(kJSIsSelecting, pp::Var(is_selecting));
+ PostMessage(message);
+}
+
void OutOfProcessInstance::ProcessPreviewPageInfo(const std::string& url,
int dst_page_index) {
if (!IsPrintPreview())

Powered by Google App Engine
This is Rietveld 408576698