OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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 | 5 |
6 /** | 6 /** |
7 * Provides the UI for dump creation. | 7 * Provides the UI for dump creation. |
8 */ | 8 */ |
9 var DumpCreator = (function() { | 9 var DumpCreator = (function() { |
10 /** | 10 /** |
(...skipping 24 matching lines...) Expand all Loading... |
35 'Enable diagnostic audio recordings.</label></p>' + | 35 'Enable diagnostic audio recordings.</label></p>' + |
36 '<p>A diagnostic audio recording is used for analyzing audio' + | 36 '<p>A diagnostic audio recording is used for analyzing audio' + |
37 ' problems. It contains the audio played out from the speaker and' + | 37 ' problems. It contains the audio played out from the speaker and' + |
38 ' recorded from the microphone and is saved to the local disk.' + | 38 ' recorded from the microphone and is saved to the local disk.' + |
39 ' Checking this box will enable the recording for an ongoing WebRTC' + | 39 ' Checking this box will enable the recording for an ongoing WebRTC' + |
40 ' call and for future WebRTC calls. When the box is unchecked or this' + | 40 ' call and for future WebRTC calls. When the box is unchecked or this' + |
41 ' page is closed, this recording functionality will be disabled for' + | 41 ' page is closed, this recording functionality will be disabled for' + |
42 ' future WebRTC calls, but an ongoing call will continue to record' + | 42 ' future WebRTC calls, but an ongoing call will continue to record' + |
43 ' until the call is ended. Only recording in one tab is supported.' + | 43 ' until the call is ended. Only recording in one tab is supported.' + |
44 ' If several tabs are running WebRTC calls, the resulting file will' + | 44 ' If several tabs are running WebRTC calls, the resulting file will' + |
45 ' be invalid.</p>'; | 45 ' be invalid. To restart the dump, the tab with the call being' + |
| 46 ' recorded must be closed and recording disabled and enabled again.' + |
| 47 ' When enabling, you select a file to save the dump to. Choose a' + |
| 48 ' non-existing file name. Selecting an existing file will append to' + |
| 49 ' it, not overwrite it, rendering the file invalid. </p>'; |
46 | 50 |
47 content.getElementsByTagName('a')[0].addEventListener( | 51 content.getElementsByTagName('a')[0].addEventListener( |
48 'click', this.onDownloadData_.bind(this)); | 52 'click', this.onDownloadData_.bind(this)); |
49 content.getElementsByTagName('input')[0].addEventListener( | 53 content.getElementsByTagName('input')[0].addEventListener( |
50 'click', this.onAecRecordingChanged_.bind(this)); | 54 'click', this.onAecRecordingChanged_.bind(this)); |
51 } | 55 } |
52 | 56 |
53 DumpCreator.prototype = { | 57 DumpCreator.prototype = { |
54 /** Mark the AEC recording checkbox checked.*/ | 58 /** Mark the AEC recording checkbox checked.*/ |
55 enableAecRecording: function() { | 59 enableAecRecording: function() { |
(...skipping 28 matching lines...) Expand all Loading... |
84 var enabled = this.root_.getElementsByTagName('input')[0].checked; | 88 var enabled = this.root_.getElementsByTagName('input')[0].checked; |
85 if (enabled) { | 89 if (enabled) { |
86 chrome.send('enableAecRecording'); | 90 chrome.send('enableAecRecording'); |
87 } else { | 91 } else { |
88 chrome.send('disableAecRecording'); | 92 chrome.send('disableAecRecording'); |
89 } | 93 } |
90 }, | 94 }, |
91 }; | 95 }; |
92 return DumpCreator; | 96 return DumpCreator; |
93 })(); | 97 })(); |
OLD | NEW |