mirror of
https://github.com/portapack-mayhem/mayhem-firmware.git
synced 2025-08-14 11:17:58 +00:00
make the ptext_prompt func can define which keyboard to enter (#2608)
* _ * format * use define
This commit is contained in:

committed by
GitHub

parent
4162820409
commit
1377516dce
@@ -25,6 +25,7 @@
|
||||
#include "ui.hpp"
|
||||
#include "ui_navigation.hpp"
|
||||
#include "ui_widget.hpp"
|
||||
#include "ui_textentry.hpp"
|
||||
|
||||
namespace ui {
|
||||
|
||||
@@ -105,7 +106,7 @@ void bind(TextField& field, T& value, NavigationView& nav, Fn fn = Fn{}) {
|
||||
// Capture a new string and make the lambda mutable so it can be modified.
|
||||
field.on_select = [&nav, buf = std::string{}](TextField& tf) mutable {
|
||||
buf = tf.get_text();
|
||||
text_prompt(nav, buf, /*max_length*/ 255,
|
||||
text_prompt(nav, buf, /*max_length*/ 255, ENTER_KEYBOARD_MODE_ALPHA,
|
||||
[&tf](std::string& str) {
|
||||
tf.set_text(str);
|
||||
});
|
||||
|
Reference in New Issue
Block a user