fix bug with keydownlistener

This commit is contained in:
Matteo Manzinello
2019-05-26 14:21:53 +02:00
parent f5d7bef15c
commit ca785d6be8
3 changed files with 18 additions and 19 deletions

7
dist/mailgo.js vendored
View File

@@ -232,9 +232,9 @@ var mailgoRender = function mailgoRender(mailgo) {
showMailgo(); // listener keyDown
mailgo.addEventListener("keydown", function () {
document.addEventListener("keydown", function () {
return mailgoKeydown(mail, cc, bcc, subject, bodyMail, url, mailtoHref, encEmail, copyButton);
}, false);
});
}; // actions
@@ -305,7 +305,8 @@ var mailgoCheckRender = function mailgoCheckRender(event) {
var mailgoKeydown = function mailgoKeydown(mail, cc, bcc, subject, bodyMail, url, mailtoHref, encEmail, copyButton) {
// if mailgo is not showing do nothing
console.log("keydown"); // if mailgo is not showing do nothing
if (!mailgoIsShowing()) return;
switch (event.keyCode) {

2
dist/mailgo.min.js vendored

File diff suppressed because one or more lines are too long