| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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('print_preview', function() { | 5 cr.define('print_preview', function() { |
| 6 'use strict'; | 6 'use strict'; |
| 7 | 7 |
| 8 /** | 8 /** |
| 9 * Object used to measure usage statistics. | 9 * Object used to measure usage statistics. |
| 10 * @constructor | 10 * @constructor |
| (...skipping 17 matching lines...) Expand all Loading... |
| 28 // Used when the user chooses to sign-in to their Google account. | 28 // Used when the user chooses to sign-in to their Google account. |
| 29 SIGNIN_TRIGGERED: 4 | 29 SIGNIN_TRIGGERED: 4 |
| 30 }; | 30 }; |
| 31 | 31 |
| 32 Metrics.prototype = { | 32 Metrics.prototype = { |
| 33 /** | 33 /** |
| 34 * Increments the counter for a given bucket. | 34 * Increments the counter for a given bucket. |
| 35 * @param {!print_preview.Metrics.Bucket} bucket Bucket to increment. | 35 * @param {!print_preview.Metrics.Bucket} bucket Bucket to increment. |
| 36 */ | 36 */ |
| 37 increment: function(bucket) { | 37 increment: function(bucket) { |
| 38 chrome.send('reportDestinationEvent', bucket); | 38 chrome.send('reportDestinationEvent', [bucket]); |
| 39 } | 39 } |
| 40 }; | 40 }; |
| 41 | 41 |
| 42 // Export | 42 // Export |
| 43 return { | 43 return { |
| 44 Metrics: Metrics | 44 Metrics: Metrics |
| 45 }; | 45 }; |
| 46 }); | 46 }); |
| OLD | NEW |