mirror of
https://github.com/meshtastic/firmware.git
synced 2025-12-13 22:32:27 +00:00
Add requestFocus() in CannedMessages (#8770)
Certain actions in CannedMessages can trigger the module losing the requestFocus bit, which puts the UI into a slightly frozen state.
This commit is contained in:
@@ -836,6 +836,7 @@ bool CannedMessageModule::handleFreeTextInput(const InputEvent *event)
|
|||||||
if (event->inputEvent == INPUT_BROKER_BACK && this->freetext.length() > 0) {
|
if (event->inputEvent == INPUT_BROKER_BACK && this->freetext.length() > 0) {
|
||||||
payload = 0x08;
|
payload = 0x08;
|
||||||
lastTouchMillis = millis();
|
lastTouchMillis = millis();
|
||||||
|
requestFocus();
|
||||||
runOnce();
|
runOnce();
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
@@ -844,6 +845,7 @@ bool CannedMessageModule::handleFreeTextInput(const InputEvent *event)
|
|||||||
if (event->inputEvent == INPUT_BROKER_LEFT) {
|
if (event->inputEvent == INPUT_BROKER_LEFT) {
|
||||||
payload = INPUT_BROKER_LEFT;
|
payload = INPUT_BROKER_LEFT;
|
||||||
lastTouchMillis = millis();
|
lastTouchMillis = millis();
|
||||||
|
requestFocus();
|
||||||
runOnce();
|
runOnce();
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
@@ -851,6 +853,7 @@ bool CannedMessageModule::handleFreeTextInput(const InputEvent *event)
|
|||||||
if (event->inputEvent == INPUT_BROKER_RIGHT) {
|
if (event->inputEvent == INPUT_BROKER_RIGHT) {
|
||||||
payload = INPUT_BROKER_RIGHT;
|
payload = INPUT_BROKER_RIGHT;
|
||||||
lastTouchMillis = millis();
|
lastTouchMillis = millis();
|
||||||
|
requestFocus();
|
||||||
runOnce();
|
runOnce();
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user