[fix] Close keyboard after calling search with preset (#13976)

This commit is contained in:
David
2025-06-23 08:22:03 +01:00
committed by GitHub
parent c456d18fa3
commit 899c257904
3 changed files with 4 additions and 2 deletions

View File

@@ -921,6 +921,7 @@ function ReaderDictionary:onShowDictionaryLookup()
buttons = dialog_buttons,
shrink_unneeded_width = true,
}
self.dictionary_lookup_dialog:onCloseKeyboard()
UIManager:show(button_dialog)
end,
}

View File

@@ -180,7 +180,7 @@ function Presets.genPresetMenuItemTable(preset_obj, text, enabled_func)
function(entered_preset_name)
local preset_data = preset_obj.buildPreset()
preset_obj.presets[entered_preset_name] = preset_data
touchmenu_instance.item_table = Presets.genPresetMenuItemTable(preset_obj)
touchmenu_instance.item_table = Presets.genPresetMenuItemTable(preset_obj, text, enabled_func)
touchmenu_instance:updateItems()
end
)
@@ -261,7 +261,7 @@ function Presets.genPresetMenuItemTable(preset_obj, text, enabled_func)
new_value = new_name
}))
end
touchmenu_instance.item_table = Presets.genPresetMenuItemTable(preset_obj)
touchmenu_instance.item_table = Presets.genPresetMenuItemTable(preset_obj, text, enabled_func)
touchmenu_instance:updateItems()
end) -- editPresetName
end, -- rename callback

View File

@@ -1490,6 +1490,7 @@ function DictQuickLookup:onLookupInputWord(hint)
buttons = dialog_buttons,
shrink_unneeded_width = true,
}
self.input_dialog:onCloseKeyboard()
UIManager:show(button_dialog)
end,
}