Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 12 additions & 3 deletions source/_remoteClient/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ def __init__(
self.localControlServer = None
self.sendingKeys = False
self._wasSendingKeysBeforeLock: bool = False
self._disconnectConfirmationDialog: Optional[MessageDialog] = None
try:
self.sdHandler = SecureDesktopHandler()
except RuntimeError:
Expand Down Expand Up @@ -222,6 +223,10 @@ def connect(self, connectionInfo: ConnectionInfo):
@alwaysCallAfter
def doDisconnect(self) -> None:
"""Seek confirmation from the user before disconnecting."""
if self._disconnectConfirmationDialog:
self._disconnectConfirmationDialog.Raise()
self._disconnectConfirmationDialog.SetFocus()
return
if (
self.followerSession is not None
and configuration.getRemoteConfig()["ui"]["confirmDisconnectAsFollower"]
Expand All @@ -247,9 +252,13 @@ def doDisconnect(self) -> None:
buttons=confirmation_buttons,
)

if dialog.ShowModal() != ReturnCode.YES:
log.info("Remote disconnection cancelled by user.")
return
self._disconnectConfirmationDialog = dialog
try:
if dialog.ShowModal() != ReturnCode.YES:
log.info("Remote disconnection cancelled by user.")
return
finally:
self._disconnectConfirmationDialog = None
self.disconnect()

def disconnect(self, *, _silent: bool = False):
Expand Down
1 change: 1 addition & 0 deletions user_docs/en/changes.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
* In Firefox browse mode, the accessible name of form controls (such as checkboxes and radio buttons) is now correctly announced when the control has an `aria-label` and an associated `<label>` element that contains only `aria-hidden` content. (#19409, @bramd)
* In Microsoft Word with UIA enabled, page changes are now correctly announced when navigating table rows that span multiple pages. (#19386, @akj)
* Fixed excessive resource usage and highlight flickering when using Visual Highlight. (#17434, @hwf1324)
* NVDA Remote Access will no longer open multiple disconnection confirmation dialogs if the action is triggered repeatedly. (#19442, @Cary-rowen)

### Changes for Developers

Expand Down
Loading