timing fix when summarizing
This commit is contained in:
parent
83543561d4
commit
e28726f30f
1 changed files with 2 additions and 0 deletions
|
|
@ -417,6 +417,8 @@ messenger.runtime.onMessage.addListener((message, sender, sendResponse) => {
|
||||||
case 'refreshTranslation':
|
case 'refreshTranslation':
|
||||||
async function _refreshTranslation(message) {
|
async function _refreshTranslation(message) {
|
||||||
let tabId = sender.tab.id;
|
let tabId = sender.tab.id;
|
||||||
|
// Fire the inline loading indicator immediately, before any await
|
||||||
|
browser.tabs.sendMessage(tabId, { command: "showTranslationGenerating" });
|
||||||
await translationStore.removeTranslation(message.headerMessageId);
|
await translationStore.removeTranslation(message.headerMessageId);
|
||||||
await _generateTranslationForMessage(message.headerMessageId, tabId);
|
await _generateTranslationForMessage(message.headerMessageId, tabId);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue