Skip to content

Commit

Permalink
Enhanced exit dialog can now be opened after closing without restarti…
Browse files Browse the repository at this point in the history
…ng NVDA
  • Loading branch information
lukaszgo1 authored and CyrilleB79 committed Nov 7, 2023
1 parent 356bd94 commit 655b92d
Showing 1 changed file with 4 additions and 10 deletions.
14 changes: 4 additions & 10 deletions addon/globalPlugins/ndtt/restartWithOptions.py
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,6 @@ def __init__(self, description, flagList, allowInSecureMode):
self.description = description
self.flagList = flagList
self.allowInSecureMode = allowInSecureMode
self.controls = []

def shouldBeDisabled(self):
return globalVars.appArgs.secure and not self.allowInSecureMode
Expand Down Expand Up @@ -159,7 +158,7 @@ def addWithGuiHelper(self, parent, sHelper):
)
checkBox.SetValue(False)
sHelper.addItem(checkBox)
self.controls.append(checkBox)
self.controls = (checkBox,)

def makeFlagValueString(self):
if self.value:
Expand All @@ -173,9 +172,6 @@ class CommandLineStringOption(CommandLineOption):
E.g. --lang=en
"""

def __init__(self, *args, **kw):
super(CommandLineStringOption, self).__init__(*args, **kw)

def makeFlagValueString(self):
val = self.value
if val:
Expand All @@ -200,7 +196,7 @@ def addWithGuiHelper(self, parent, sHelper):
choices=self.choices,
)
choice.SetSelection(0)
self.controls.append(choice)
self.controls = (choice,)

@property
def value(self):
Expand Down Expand Up @@ -245,8 +241,7 @@ def addWithGuiHelper(self, parent, sHelper):

fileEdit = fileEntryControl.pathControl
fileEdit.Value = ""
self.controls.append(fileEdit)
self.controls.append(fileEntryControl._browseButton)
self.controls = (fileEdit, fileEntryControl._browseButton)


class CommandLineFolderOption(CommandLineStringOption):
Expand All @@ -267,8 +262,7 @@ def addWithGuiHelper(self, parent, sHelper):
directoryEntryControl = groupHelper.addItem(directoryPathHelper)
directoryEdit = directoryEntryControl.pathControl
directoryEdit.Value = ""
self.controls.append(directoryEdit)
self.controls.append(directoryEntryControl._browseButton)
self.controls = (directoryEdit, directoryEntryControl._browseButton)


class RestartWithOptionsDialog(gui.settingsDialogs.SettingsDialog):
Expand Down

0 comments on commit 655b92d

Please sign in to comment.