fix: screen update is faster
This commit is contained in:
parent
dfef1c583a
commit
4c8ae34d0e
1 changed files with 0 additions and 5 deletions
|
@ -50,10 +50,6 @@ const MCDU = (function () {
|
||||||
img.addEventListener('error', reject);
|
img.addEventListener('error', reject);
|
||||||
|
|
||||||
img.addEventListener('load', (event) => {
|
img.addEventListener('load', (event) => {
|
||||||
const gotCacheBust = parseInt(event.target.src.split('cacheBust=')[1]) || 0;
|
|
||||||
if (gotCacheBust !== currentCacheBust) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
showScreenImageLoadState(true);
|
showScreenImageLoadState(true);
|
||||||
resolve(url);
|
resolve(url);
|
||||||
});
|
});
|
||||||
|
@ -160,7 +156,6 @@ const MCDU = (function () {
|
||||||
]
|
]
|
||||||
});
|
});
|
||||||
request.send(body);
|
request.send(body);
|
||||||
setTimeout(refreshScreen, 150);
|
|
||||||
return new Promise((resolve) => {
|
return new Promise((resolve) => {
|
||||||
request.addEventListener('load', () => {
|
request.addEventListener('load', () => {
|
||||||
lastSentText = text;
|
lastSentText = text;
|
||||||
|
|
Loading…
Reference in a new issue