OLD | NEW |
---|---|
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 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 * @fileoverview App launcher start page implementation. | 6 * @fileoverview App launcher start page implementation. |
7 */ | 7 */ |
8 | 8 |
9 <include src="speech_manager.js"> | 9 <include src="speech_manager.js"> |
10 | 10 |
(...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
127 } | 127 } |
128 | 128 |
129 /** | 129 /** |
130 * Invoked when the user explicitly wants to toggle the speech recognition | 130 * Invoked when the user explicitly wants to toggle the speech recognition |
131 * state. | 131 * state. |
132 */ | 132 */ |
133 function toggleSpeechRecognition() { | 133 function toggleSpeechRecognition() { |
134 speechManager.toggleSpeechRecognition(); | 134 speechManager.toggleSpeechRecognition(); |
135 } | 135 } |
136 | 136 |
137 function onSearchEngineChanged(is_google) { | |
138 $('logo_container').style.display = is_google ? 'block' : 'none'; | |
Matt Giuca
2015/02/10 08:27:05
Can't we just hide the whole WebContents in this c
calamity
2015/02/13 02:55:24
That's a good point. Done.
| |
139 } | |
140 | |
137 return { | 141 return { |
138 initialize: initialize, | 142 initialize: initialize, |
139 setHotwordEnabled: setHotwordEnabled, | 143 setHotwordEnabled: setHotwordEnabled, |
140 setNaclArch: setNaclArch, | 144 setNaclArch: setNaclArch, |
141 onAppListDoodleUpdated: onAppListDoodleUpdated, | 145 onAppListDoodleUpdated: onAppListDoodleUpdated, |
146 onSearchEngineChanged: onSearchEngineChanged, | |
142 onAppListShown: onAppListShown, | 147 onAppListShown: onAppListShown, |
143 onAppListHidden: onAppListHidden, | 148 onAppListHidden: onAppListHidden, |
144 toggleSpeechRecognition: toggleSpeechRecognition | 149 toggleSpeechRecognition: toggleSpeechRecognition |
145 }; | 150 }; |
146 }); | 151 }); |
147 | 152 |
148 document.addEventListener('contextmenu', function(e) { e.preventDefault(); }); | 153 document.addEventListener('contextmenu', function(e) { e.preventDefault(); }); |
149 document.addEventListener('DOMContentLoaded', appList.startPage.initialize); | 154 document.addEventListener('DOMContentLoaded', appList.startPage.initialize); |
OLD | NEW |