Commit 13a39105 authored by Lei Zhang's avatar Lei Zhang Committed by Commit Bot

Fix nits in the Print Preview header/footer template.

Give setup() a more distinctive name, and add a missing <html> tag.

Change-Id: I81e42c231afdce5cf574e14927621a959c19c5b1
Reviewed-on: https://chromium-review.googlesource.com/c/1357728Reviewed-by: default avatarRebekah Potter <rbpotter@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
Cr-Commit-Position: refs/heads/master@{#613259}
parent c36d09a9
...@@ -105,7 +105,7 @@ bool g_is_preview_enabled = false; ...@@ -105,7 +105,7 @@ bool g_is_preview_enabled = false;
const char kPageLoadScriptFormat[] = const char kPageLoadScriptFormat[] =
"document.open(); document.write(%s); document.close();"; "document.open(); document.write(%s); document.close();";
const char kPageSetupScriptFormat[] = "setup(%s);"; const char kPageSetupScriptFormat[] = "setupHeaderFooterTemplate(%s);";
void ExecuteScript(blink::WebLocalFrame* frame, void ExecuteScript(blink::WebLocalFrame* frame,
const char* script_format, const char* script_format,
......
<!doctype html> <!doctype html>
<html>
<head> <head>
<link rel="stylesheet" href="chrome://resources/css/text_defaults.css"> <link rel="stylesheet" href="chrome://resources/css/text_defaults.css">
<style> <style>
...@@ -60,7 +61,7 @@ ...@@ -60,7 +61,7 @@
</style> </style>
<script> <script>
function setup(options) { function setupHeaderFooterTemplate(options) {
const body = document.querySelector('body'); const body = document.querySelector('body');
const header = document.querySelector('#header'); const header = document.querySelector('#header');
const footer = document.querySelector('#footer'); const footer = document.querySelector('#footer');
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment