fix(autofill): refusing a request must not move any window
The busy guard cancelled through the path that hands the foreground back to the captured target. During an export that pushed the native Save dialog behind the other application, leaving the app disabled by a modal the user could no longer find. refocus=0 separates refusing a request from ending a user interaction.
This commit is contained in:
+4
-1
@@ -242,7 +242,10 @@ async function autofillHandleRequest(windowTitle, kind) {
|
||||
// window and hand the foreground away mid-operation. cancelAutofill so
|
||||
// Delphi doesn't keep the captured target HWND for a fill that never comes.
|
||||
if (typeof isBusy === 'function' && isBusy()) {
|
||||
Bridge.cancelAutofill();
|
||||
// refocus=false: refusing must not move any window. During an export a
|
||||
// native Save dialog holds the foreground, and shoving it behind leaves
|
||||
// the app disabled by a modal the user can no longer find.
|
||||
Bridge.cancelAutofill(false);
|
||||
toast('Busy — try again in a moment', 'warning');
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user