mirror of
https://github.com/ArchipelagoMW/Archipelago.git
synced 2026-03-30 14:53:28 -07:00
Options Creator: bind free text set_value to text instead of on_text_validate (#5915)
This commit is contained in:
@@ -384,10 +384,11 @@ class OptionsCreator(ThemedApp):
|
||||
def create_free_text(self, option: typing.Type[FreeText] | typing.Type[TextChoice], name: str):
|
||||
text = VisualFreeText(option=option, name=name)
|
||||
|
||||
def set_value(instance):
|
||||
self.options[name] = instance.text
|
||||
def set_value(instance, value):
|
||||
self.options[name] = value
|
||||
|
||||
text.bind(on_text_validate=set_value)
|
||||
text.bind(text=set_value)
|
||||
self.options[name] = option.default
|
||||
return text
|
||||
|
||||
def create_choice(self, option: typing.Type[Choice], name: str):
|
||||
|
||||
Reference in New Issue
Block a user