mirror of
https://github.com/UpsilonNumworks/Upsilon.git
synced 2026-03-21 14:50:44 +01:00
[apps/graph/graph] Add a banner view in the graph view
Change-Id: Iafa0dcfc730911264d5b045c14bde54f432f53a2
This commit is contained in:
@@ -6,7 +6,6 @@ namespace Graph {
|
||||
CurveParameterController::CurveParameterController(GraphView * graphView) :
|
||||
ViewController(nullptr),
|
||||
m_graphView(graphView),
|
||||
m_displayDerivative(false),
|
||||
m_function(nullptr),
|
||||
m_calculationCell(ChevronMenuListCell((char*)"Calculer")),
|
||||
m_goToCell(ChevronMenuListCell((char*)"Aller a")),
|
||||
@@ -33,7 +32,7 @@ void CurveParameterController::didBecomeFirstResponder() {
|
||||
void CurveParameterController::willDisplayCellForIndex(TableViewCell * cell, int index) {
|
||||
if (cell == &m_derivativeCell) {
|
||||
SwitchView * switchView = (SwitchView *)m_derivativeCell.accessoryView();
|
||||
switchView->setState(m_displayDerivative);
|
||||
switchView->setState(m_graphView->bannerView()->displayDerivative());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -50,7 +49,7 @@ bool CurveParameterController::handleEvent(Ion::Events::Event event) {
|
||||
return true;
|
||||
}
|
||||
case 2:
|
||||
m_displayDerivative = !m_displayDerivative;
|
||||
m_graphView->bannerView()->setDisplayDerivative(!m_graphView->bannerView()->displayDerivative());
|
||||
m_selectableTableView.reloadData();
|
||||
return true;
|
||||
default:
|
||||
@@ -79,10 +78,6 @@ KDCoordinate CurveParameterController::cellHeight() {
|
||||
return 35;
|
||||
}
|
||||
|
||||
bool CurveParameterController::displayDerivative() const {
|
||||
return m_displayDerivative;
|
||||
}
|
||||
|
||||
void CurveParameterController::setFunction(Function * function) {
|
||||
m_function = function;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user