OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 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 | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 cr.define('DomainReliabilityInternals', function() { | 5 cr.define('DomainReliabilityInternals', function() { |
6 'use strict'; | 6 'use strict'; |
7 | 7 |
8 function initialize() { | 8 function initialize() { |
9 chrome.send('updateData'); | 9 chrome.send('updateData'); |
10 } | 10 } |
11 | 11 |
12 function onDataUpdated(data) { | 12 function onDataUpdated(data) { |
13 jstProcess(new JsEvalContext(data), $('template')); | 13 jstProcess(new JsEvalContext(data), $('template')); |
14 } | 14 } |
15 | 15 |
16 // Return an object with all of the exports. | 16 // Return an object with all of the exports. |
17 return { | 17 return { |
18 initialize: initialize, | 18 initialize: initialize, |
19 onDataUpdated: onDataUpdated, | 19 onDataUpdated: onDataUpdated, |
20 }; | 20 }; |
21 }); | 21 }); |
22 | 22 |
23 document.addEventListener('DOMContentLoaded', | 23 document.addEventListener( |
24 DomainReliabilityInternals.initialize); | 24 'DOMContentLoaded', DomainReliabilityInternals.initialize); |
OLD | NEW |