MCPcopy Index your code
hub / github.com/mailvelope/mailvelope / onEditorClose

Method onEditorClose

src/controller/editor.controller.js:189–201  ·  view source on GitHub ↗
(option = {cancel: false})

Source from the content-addressed store, hash-verified

187 }
188
189 async onEditorClose(option = {cancel: false}) {
190 const {cancel} = option;
191 const popup = await this.getPopup();
192 if (popup) {
193 popup.close();
194 this.popup = null;
195 this.setState({popupId: null, popupOpenerTabId: null});
196 if (cancel) {
197 const peerController = this.peers.gmailController ?? this.peers.encryptController;
198 peerController.encryptError(new MvError('Editor dialog canceled.', 'EDITOR_DIALOG_CANCEL'));
199 }
200 }
201 }
202
203 async onEditorContainerEncrypt(msg) {
204 this.pgpMIME = true;

Callers 3

getPopupMethod · 0.95
openEditorMethod · 0.95
onEditorPlaintextMethod · 0.95

Calls 4

getPopupMethod · 0.95
closeMethod · 0.80
setStateMethod · 0.45
encryptErrorMethod · 0.45

Tested by

no test coverage detected