Index: pdf/out_of_process_instance.cc |
diff --git a/pdf/out_of_process_instance.cc b/pdf/out_of_process_instance.cc |
index d1fd4173d8c48c40bc5b40b5f0835426b8a69e89..37872b8bc370fdcbbec77501b20be17c4ce980af 100644 |
--- a/pdf/out_of_process_instance.cc |
+++ b/pdf/out_of_process_instance.cc |
@@ -132,6 +132,8 @@ const char kJSEmailCc[] = "cc"; |
const char kJSEmailBcc[] = "bcc"; |
const char kJSEmailSubject[] = "subject"; |
const char kJSEmailBody[] = "body"; |
+// Handle open PDF parameters. |
+const char kJSHandleOpenPDFParams[] = "openPDFParams"; |
const int kFindResultCooldownMs = 100; |
@@ -1074,9 +1076,9 @@ void OutOfProcessInstance::DocumentLoadComplete(int page_count) { |
// Note: If we are in print preview mode the scroll location is retained |
// across document loads so we don't want to scroll again and override it. |
if (!IsPrintPreview()) { |
- int initial_page = GetInitialPage(url_); |
- if (initial_page >= 0) |
- ScrollToPage(initial_page); |
+ pp::VarDictionary message; |
+ message.Set(pp::Var(kType), pp::Var(kJSHandleOpenPDFParams)); |
+ PostMessage(message); |
raymes
2014/08/15 01:07:18
I don't think we need to add this new message type
Nikhil
2014/08/16 10:24:01
Done.
|
} else { |
AppendBlankPrintPreviewPages(); |
OnGeometryChanged(0, 0); |