| 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 <include src="keyboard_overlay_accessibility_helper.js"/> | 6 <include src="keyboard_overlay_accessibility_helper.js"/> |
| 7 | 7 |
| 8 var BASE_KEYBOARD = { | 8 var BASE_KEYBOARD = { |
| 9 top: 0, | 9 top: 0, |
| 10 left: 0, | 10 left: 0, |
| (...skipping 20 matching lines...) Expand all Loading... |
| 31 '1D': 'is-ctrl', | 31 '1D': 'is-ctrl', |
| 32 '38': 'is-alt', | 32 '38': 'is-alt', |
| 33 'E0 5B': 'is-search' | 33 'E0 5B': 'is-search' |
| 34 }; | 34 }; |
| 35 | 35 |
| 36 var LABEL_TO_IDENTIFIER = { | 36 var LABEL_TO_IDENTIFIER = { |
| 37 'search': 'E0 5B', | 37 'search': 'E0 5B', |
| 38 'ctrl': '1D', | 38 'ctrl': '1D', |
| 39 'alt': '38', | 39 'alt': '38', |
| 40 'caps lock': '3A', | 40 'caps lock': '3A', |
| 41 'esc': '01', |
| 41 'disabled': 'DISABLED' | 42 'disabled': 'DISABLED' |
| 42 }; | 43 }; |
| 43 | 44 |
| 44 var KEYCODE_TO_LABEL = { | 45 var KEYCODE_TO_LABEL = { |
| 45 8: 'backspace', | 46 8: 'backspace', |
| 46 9: 'tab', | 47 9: 'tab', |
| 47 13: 'enter', | 48 13: 'enter', |
| 48 27: 'esc', | 49 27: 'esc', |
| 49 32: 'space', | 50 32: 'space', |
| 50 33: 'pageup', | 51 33: 'pageup', |
| (...skipping 635 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 686 * Handles click events of the learn more link. | 687 * Handles click events of the learn more link. |
| 687 * @param {Event} e Mouse click event. | 688 * @param {Event} e Mouse click event. |
| 688 */ | 689 */ |
| 689 function learnMoreClicked(e) { | 690 function learnMoreClicked(e) { |
| 690 chrome.send('openLearnMorePage'); | 691 chrome.send('openLearnMorePage'); |
| 691 chrome.send('DialogClose'); | 692 chrome.send('DialogClose'); |
| 692 e.preventDefault(); | 693 e.preventDefault(); |
| 693 } | 694 } |
| 694 | 695 |
| 695 document.addEventListener('DOMContentLoaded', init); | 696 document.addEventListener('DOMContentLoaded', init); |
| OLD | NEW |