[hardware test] Use a BankViewController

And add a SerialNumberController
This commit is contained in:
Romain Goyet
2018-05-04 15:53:53 +02:00
committed by Ecco
parent 69545b9cf9
commit 71f9ce3b67
16 changed files with 250 additions and 55 deletions

View File

@@ -10,8 +10,7 @@ namespace HardwareTest {
KeyboardTestController::KeyboardTestController(Responder * parentResponder) :
ViewController(parentResponder),
m_keyboardView(),
m_screenTestController(nullptr)
m_keyboardView()
{
}
@@ -25,8 +24,8 @@ bool KeyboardTestController::handleEvent(Ion::Events::Event event) {
if (state == onlyKeyDown) {
m_keyboardView.setTestedKeyIndex(m_keyboardView.testedKeyIndex()+1);
if (m_keyboardView.testedKeyIndex() == Ion::Keyboard::NumberOfValidKeys) {
ModalViewController * modal = (ModalViewController *)parentResponder();
modal->displayModalViewController(&m_screenTestController, 0.0f, 0.0f);
// Returning false will go to the next step in the WizardViewController
return false;
}
}
return true;