Moved restore speech on prompt to existing temp interrupt speech command, Fenrir+kp_plus unbound now.
This commit is contained in:
@ -20,6 +20,9 @@ class command():
|
||||
return
|
||||
self.env['runtime']['settingsManager'].setSetting('speech', 'enabled', str(self.env['commandBuffer']['enableSpeechOnKeypress']))
|
||||
self.env['commandBuffer']['enableSpeechOnKeypress'] = False
|
||||
# Also disable prompt watching since speech was manually re-enabled
|
||||
if 'silenceUntilPrompt' in self.env['commandBuffer']:
|
||||
self.env['commandBuffer']['silenceUntilPrompt'] = False
|
||||
self.env['runtime']['outputManager'].presentText(_("speech enabled"), soundIcon='SpeechOn', interrupt=True)
|
||||
|
||||
def setCallback(self, callback):
|
||||
|
@ -24,6 +24,9 @@ class command():
|
||||
return
|
||||
self.env['runtime']['settingsManager'].setSetting('speech', 'enabled', str(self.env['commandBuffer']['enableSpeechOnKeypress']))
|
||||
self.env['commandBuffer']['enableSpeechOnKeypress'] = False
|
||||
# Also disable prompt watching since speech was manually re-enabled
|
||||
if 'silenceUntilPrompt' in self.env['commandBuffer']:
|
||||
self.env['commandBuffer']['silenceUntilPrompt'] = False
|
||||
self.env['runtime']['outputManager'].presentText(_("speech enabled"), soundIcon='SpeechOn', interrupt=True)
|
||||
|
||||
def setCallback(self, callback):
|
||||
|
@ -118,6 +118,9 @@ class command():
|
||||
"""Helper method to restore speech when prompt is detected"""
|
||||
# Disable silence mode
|
||||
self.env['commandBuffer']['silenceUntilPrompt'] = False
|
||||
# Also disable the keypress-based speech restoration since we're enabling it now
|
||||
if 'enableSpeechOnKeypress' in self.env['commandBuffer']:
|
||||
self.env['commandBuffer']['enableSpeechOnKeypress'] = False
|
||||
# Re-enable speech
|
||||
self.env['runtime']['settingsManager'].setSetting('speech', 'enabled', 'True')
|
||||
self.env['runtime']['outputManager'].presentText(_("Speech restored"), soundIcon='SpeechOn', interrupt=True)
|
||||
|
Reference in New Issue
Block a user