1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
6 * Javascript for local_state.html, served from chrome://local-state/
7 * This is used to debug the contents of the Local State file.
10 cr.define('localState', function() {
14 * Sets the page content to the specified |localState| string, called
16 * @param {string} localState the JSON-formatted local state data,
17 * or an error message.
19 function setLocalState(localState) {
20 $('content').textContent = localState;
24 setLocalState: setLocalState
28 // When the page loads, request the JSON local state data from C++.
29 document.addEventListener('DOMContentLoaded', function() {
30 chrome.send('requestJson');