run-dialog: Don't call popModal before attempting to execute a command
Do it only on success, so we avoid the active window state changes, which are confusing screen readers.
Fixes #6925.
Do it only on success, so we avoid the active window state changes, which are confusing screen readers.
Fixes #6925.