File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -88,6 +88,7 @@ def doStartupDialogs():
8888 gui .mainFrame .onToggleSpeechViewerCommand (evt = None )
8989 import inputCore
9090 if inputCore .manager .userGestureMap .lastUpdateContainedError :
91+ import wx
9192 gui .messageBox (_ ("Your gesture map file contains errors.\n "
9293 "More details about the errors can be found in the log file." ),
9394 _ ("gesture map File Error" ), wx .OK | wx .ICON_EXCLAMATION )
@@ -99,6 +100,7 @@ def doStartupDialogs():
99100 if updateCheck and not config .conf ['update' ]['askedAllowUsageStats' ]:
100101 # a callback to save config after the usage stats question dialog has been answered.
101102 def onResult (ID ):
103+ import wx
102104 if ID in (wx .ID_YES ,wx .ID_NO ):
103105 try :
104106 config .conf .save ()
@@ -110,6 +112,7 @@ def onResult(ID):
110112def restart (disableAddons = False , debugLogging = False ):
111113 """Restarts NVDA by starting a new copy."""
112114 if globalVars .appArgs .launcher :
115+ import wx
113116 globalVars .exitCode = 3
114117 wx .GetApp ().ExitMainLoop ()
115118 return
@@ -208,7 +211,7 @@ def _setInitialFocus():
208211 log .exception ("Error retrieving initial focus" )
209212
210213
211- def getWxLangOrNone () -> Optional [' wx.LanguageInfo' ]:
214+ def getWxLangOrNone () -> Optional [wx .LanguageInfo ]:
212215 import languageHandler
213216 import wx
214217 lang = languageHandler .getLanguage ()
You can’t perform that action at this time.
0 commit comments