| 14 | |
| 15 | export default class PwdController extends SubController { |
| 16 | constructor() { |
| 17 | super(); |
| 18 | this.persistent = true; |
| 19 | this.mainType = 'pwdDialog'; |
| 20 | this.id = getUUID(); |
| 21 | this.queue = new PromiseQueue(); |
| 22 | this.pwdPopup = null; |
| 23 | this.receivedPortMsg = false; |
| 24 | this.options = null; |
| 25 | this.passwordRequest = null; |
| 26 | // register event handlers |
| 27 | this.on('pwd-dialog-init', this.onPwdDialogInit); |
| 28 | this.on('pwd-dialog-cancel', this.onCancel); |
| 29 | this.on('pwd-dialog-ok', this.onOk); |
| 30 | this.on('pwd-user-input', msg => uiLog.push(msg.source, msg.type)); |
| 31 | } |
| 32 | |
| 33 | async onPwdDialogInit() { |
| 34 | // pass over keyId and userId to dialog |