move variable assignment
This commit is contained in:
parent
3aee254de2
commit
02f73e6be6
@ -39,8 +39,6 @@ impl AutoComplete {
|
|||||||
let enter_pressed = ui.input_mut().consume_key(Modifiers::NONE, Key::Enter);
|
let enter_pressed = ui.input_mut().consume_key(Modifiers::NONE, Key::Enter);
|
||||||
let tab_pressed = ui.input_mut().consume_key(Modifiers::NONE, Key::Tab);
|
let tab_pressed = ui.input_mut().consume_key(Modifiers::NONE, Key::Tab);
|
||||||
|
|
||||||
let te_id = ui.make_persistent_id(format!("text_edit_ac_{}", func_i));
|
|
||||||
|
|
||||||
// update self
|
// update self
|
||||||
self.changed(&string);
|
self.changed(&string);
|
||||||
|
|
||||||
@ -48,6 +46,8 @@ impl AutoComplete {
|
|||||||
.hint_forward(true) // Make the hint appear after the last text in the textbox
|
.hint_forward(true) // Make the hint appear after the last text in the textbox
|
||||||
.lock_focus(true);
|
.lock_focus(true);
|
||||||
|
|
||||||
|
let te_id = ui.make_persistent_id(format!("text_edit_ac_{}", func_i));
|
||||||
|
|
||||||
if self.hint.is_none() {
|
if self.hint.is_none() {
|
||||||
let re = func_edit.id(te_id).ui(ui);
|
let re = func_edit.id(te_id).ui(ui);
|
||||||
let return_string = (&new_string).to_string();
|
let return_string = (&new_string).to_string();
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user