Fix DisplayGenerator not working on pitch-accents-preview.html (#1276)
This commit is contained in:
parent
21fce9f3d9
commit
3c51bf2a0b
@ -22,7 +22,7 @@
|
||||
*/
|
||||
|
||||
class DisplayGenerator {
|
||||
constructor({japaneseUtil, mediaLoader, hotkeyHelpController}) {
|
||||
constructor({japaneseUtil, mediaLoader, hotkeyHelpController=null}) {
|
||||
this._japaneseUtil = japaneseUtil;
|
||||
this._mediaLoader = mediaLoader;
|
||||
this._hotkeyHelpController = hotkeyHelpController;
|
||||
@ -38,6 +38,7 @@ class DisplayGenerator {
|
||||
|
||||
updateHotkeys() {
|
||||
const hotkeyHelpController = this._hotkeyHelpController;
|
||||
if (hotkeyHelpController === null) { return; }
|
||||
for (const template of this._templates.getAllTemplates()) {
|
||||
hotkeyHelpController.setupNode(template.content);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user