| 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 <include src="keyboard_overlay_data.js"> | 5 <include src="keyboard_overlay_data.js"> |
| 6 | 6 |
| 7 var BASE_KEYBOARD = { | 7 var BASE_KEYBOARD = { |
| 8 top: 0, | 8 top: 0, |
| 9 left: 0, | 9 left: 0, |
| 10 width: 1237, | 10 width: 1237, |
| (...skipping 23 matching lines...) Expand all Loading... |
| 34 'E0 38': 'is-alt', | 34 'E0 38': 'is-alt', |
| 35 'E0 5B': 'is-search' | 35 'E0 5B': 'is-search' |
| 36 }; | 36 }; |
| 37 | 37 |
| 38 var LABEL_TO_IDENTIFIER = { | 38 var LABEL_TO_IDENTIFIER = { |
| 39 'search': 'E0 5B', | 39 'search': 'E0 5B', |
| 40 'ctrl': '1D', | 40 'ctrl': '1D', |
| 41 'alt': '38', | 41 'alt': '38', |
| 42 'caps lock': '3A', | 42 'caps lock': '3A', |
| 43 'esc': '01', | 43 'esc': '01', |
| 44 'backspace': '0E', |
| 44 'disabled': 'DISABLED' | 45 'disabled': 'DISABLED' |
| 45 }; | 46 }; |
| 46 | 47 |
| 47 var KEYCODE_TO_LABEL = { | 48 var KEYCODE_TO_LABEL = { |
| 48 8: 'backspace', | 49 8: 'backspace', |
| 49 9: 'tab', | 50 9: 'tab', |
| 50 13: 'enter', | 51 13: 'enter', |
| 51 27: 'esc', | 52 27: 'esc', |
| 52 32: 'space', | 53 32: 'space', |
| 53 33: 'pageup', | 54 33: 'pageup', |
| (...skipping 813 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 867 function onWidgetShown() { | 868 function onWidgetShown() { |
| 868 setTimeout(function() { | 869 setTimeout(function() { |
| 869 // Show and focus the instructions div after a delay so that chrome vox | 870 // Show and focus the instructions div after a delay so that chrome vox |
| 870 // speaks it correctly. | 871 // speaks it correctly. |
| 871 $('instructions').style.visibility = 'visible'; | 872 $('instructions').style.visibility = 'visible'; |
| 872 $('instructions').focus(); | 873 $('instructions').focus(); |
| 873 }, 500); | 874 }, 500); |
| 874 } | 875 } |
| 875 | 876 |
| 876 document.addEventListener('DOMContentLoaded', init); | 877 document.addEventListener('DOMContentLoaded', init); |
| OLD | NEW |