Changed custom key binding config properties to use 'keyCode' instead of 'code'
This commit is contained in:
		| @@ -1098,8 +1098,8 @@ | |||||||
| 	 * Add a custom key binding with optional description to be added to the help screen | 	 * Add a custom key binding with optional description to be added to the help screen | ||||||
| 	 */ | 	 */ | ||||||
| 	function addKeyBinding(binding, callback) { | 	function addKeyBinding(binding, callback) { | ||||||
| 		if (typeof binding === 'object' && binding.code) { | 		if (typeof binding === 'object' && binding.keyCode) { | ||||||
| 			registeredKeyBindings[binding.code] = { | 			registeredKeyBindings[binding.keyCode] = { | ||||||
| 				callback: callback, | 				callback: callback, | ||||||
| 				key: binding.key, | 				key: binding.key, | ||||||
| 				description: binding.description | 				description: binding.description | ||||||
|   | |||||||
| @@ -106,7 +106,7 @@ var RevealNotes = (function() { | |||||||
| 		} | 		} | ||||||
|  |  | ||||||
| 		// Open the notes when the 's' key is hit | 		// Open the notes when the 's' key is hit | ||||||
| 		Reveal.addKeyBinding({code: 83, key: 'S', description: 'Speaker notes'}, openNotes); | 		Reveal.addKeyBinding({keyCode: 83, key: 'S', description: 'Speaker notes'}, openNotes); | ||||||
|  |  | ||||||
| 	} | 	} | ||||||
|  |  | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user