mirror of
https://github.com/UpsilonNumworks/Upsilon.git
synced 2026-03-30 04:00:02 +02:00
[ion] Update the Event model
Change-Id: I41a53caeb7dd8a15e7934f49675f6a53be8fe7be
This commit is contained in:
committed by
Émilie Feral
parent
b220ed5dd8
commit
b87f06e3a2
@@ -49,18 +49,17 @@ bool InputViewController::handleEvent(Ion::Events::Event event) {
|
||||
if (!isDisplayingModal()) {
|
||||
return false;
|
||||
}
|
||||
switch (event) {
|
||||
case Ion::Events::Event::ENTER:
|
||||
m_successAction.perform(this);
|
||||
dismissModalViewController();
|
||||
return true;
|
||||
case Ion::Events::Event::ESC:
|
||||
m_failureAction.perform(this);
|
||||
dismissModalViewController();
|
||||
return true;
|
||||
default:
|
||||
return false;
|
||||
if (event == Ion::Events::OK) {
|
||||
m_successAction.perform(this);
|
||||
dismissModalViewController();
|
||||
return true;
|
||||
}
|
||||
if (event == Ion::Events::Back) {
|
||||
m_failureAction.perform(this);
|
||||
dismissModalViewController();
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
void InputViewController::edit(Responder * caller, const char * initialContent, void * context, Invocation::Action successAction, Invocation::Action failureAction) {
|
||||
|
||||
Reference in New Issue
Block a user