Changed selected button when keyboard is called (#144)

* Changed selected button when keyboard is called

* chnaged comment in keyboardmanager.cpp

* chnaged comment in keyboardmanager.cpp and replaced number with index
This commit is contained in:
FennecTECH 2018-09-03 14:13:42 -05:00 committed by Bernardo Giordano
parent 3973996313
commit fad48c1148

View file

@ -226,10 +226,10 @@ KeyboardManager::KeyboardManager(void)
);
buttons.push_back(spacebar);
// set first button as selected
buttons.at(0)->selected(true);
buttons.at(0)->invertColors();
prevSelectedButtonIndex = 0;
// set OK button as selected
buttons.at(INDEX_OK)->selected(true);
buttons.at(INDEX_OK)->invertColors();
prevSelectedButtonIndex = INDEX_OK;
}
KeyboardManager::~KeyboardManager(void)
@ -362,4 +362,4 @@ std::pair<bool, std::string> KeyboardManager::keyboard(const std::string& sugges
}
return std::make_pair(false, suggestion);
}
}