Index: chrome/browser/printing/print_preview_pdf_generated_browsertest.cc |
diff --git a/chrome/browser/printing/print_preview_pdf_generated_browsertest.cc b/chrome/browser/printing/print_preview_pdf_generated_browsertest.cc |
index 58c1104bd0e9c38b6e44f05ca35d0aa41a910e12..3a47bb1a1a1d5514c29337a3362459d9715f4c39 100644 |
--- a/chrome/browser/printing/print_preview_pdf_generated_browsertest.cc |
+++ b/chrome/browser/printing/print_preview_pdf_generated_browsertest.cc |
@@ -209,8 +209,7 @@ class PrintPreviewObserver : public WebContentsObserver { |
} |
ASSERT_FALSE(script_argument.empty()); |
- GetUI()->web_ui()->CallJavascriptFunctionUnsafe( |
- "onManipulateSettingsForTest", script_argument); |
+ GetUI()->SendManipulateSettingsForTest(script_argument); |
} |
// Saves the print preview settings to be sent to the print preview dialog. |
@@ -283,8 +282,7 @@ class PrintPreviewObserver : public WebContentsObserver { |
ui->web_ui()->AddMessageHandler( |
base::MakeUnique<UIDoneLoadingMessageHandler>(this)); |
- ui->web_ui()->CallJavascriptFunctionUnsafe( |
- "onEnableManipulateSettingsForTest"); |
+ ui->SendEnableManipulateSettingsForTest(); |
} |
void DidCloneToNewWebContents(WebContents* old_web_contents, |