From ce73c60e2f04bcb92c2a799ebd3121f10606441e Mon Sep 17 00:00:00 2001 From: sienori Date: Thu, 7 Feb 2019 02:24:00 +0900 Subject: [PATCH] Translate text when pasted into popup --- simple-translate/popup/popup.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/simple-translate/popup/popup.js b/simple-translate/popup/popup.js index e29fb40..3708e59 100644 --- a/simple-translate/popup/popup.js +++ b/simple-translate/popup/popup.js @@ -119,7 +119,10 @@ function refleshSource() { } } -textarea.addEventListener("paste", resize); +textarea.addEventListener("paste", () => { + resize(); + inputText(); +}); textarea.addEventListener("keydown", resize);