Fixed a bug where a resumed recording wouldn't update the image
Template tests / tests (push) Successful in 1m54s

This commit is contained in:
Iisyourdad
2026-06-11 11:48:09 -05:00
parent 3df52e37fc
commit 72b3f10a8a
2 changed files with 12 additions and 0 deletions
+8
View File
@@ -201,6 +201,14 @@ class CaptureService {
};
if (this.hiddenForSession && win && !win.isDestroyed()) setTimeout(arm, 400);
else arm();
} else if (!wasPaused && this.session.paused) {
// Pausing stops the background cache refresh loop, but it does so by
// returning early (see startClickCaptureCache's refresh) without
// resetting captureCacheRunning or clearing captureCache. Without this
// call, resuming would find captureCacheRunning still true, so
// startClickCaptureCache() would no-op and every click afterwards
// would reuse the stale pre-pause frame instead of a fresh one.
this.stopClickCaptureCache();
}
if (this.rebuildTrayMenu) this.rebuildTrayMenu();
this.notify('capture:state', this.state());