mirror of
https://github.com/UpsilonNumworks/Upsilon.git
synced 2026-03-19 05:40:38 +01:00
[apps/graph/list] Handle right event to open submenu
This commit is contained in:
@@ -23,6 +23,20 @@ HighlightCell * ListParameterController::reusableCell(int index, int type) {
|
||||
}
|
||||
}
|
||||
|
||||
bool ListParameterController::handleEvent(Ion::Events::Event event) {
|
||||
if (Shared::ListParameterController::handleEvent(event)) {
|
||||
return true;
|
||||
}
|
||||
if (event == Ion::Events::Right) {
|
||||
int selectedR = selectedRow();
|
||||
if (selectedR == 0 || selectedR == 1) {
|
||||
// Go in the submenu
|
||||
return handleEnterOnRow(selectedR);
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
void ListParameterController::willDisplayCellForIndex(HighlightCell * cell, int index) {
|
||||
Shared::ListParameterController::willDisplayCellForIndex(cell, index);
|
||||
if ((cell == &m_typeCell || cell == &m_functionDomain) && !m_record.isNull()) {
|
||||
|
||||
@@ -19,6 +19,7 @@ public:
|
||||
m_domainParameterController(nullptr, inputEventHandlerDelegate),
|
||||
m_renameCell(I18n::Message::Rename)
|
||||
{}
|
||||
bool handleEvent(Ion::Events::Event event) override;
|
||||
// ListViewDataSource
|
||||
HighlightCell * reusableCell(int index, int type) override;
|
||||
void willDisplayCellForIndex(HighlightCell * cell, int index) override;
|
||||
|
||||
Reference in New Issue
Block a user