[apps/graph] ValuesController: column width are different for parametric

functions
This commit is contained in:
Émilie Feral
2019-09-24 17:32:42 +02:00
committed by LeaNumworks
parent bf23e0f8da
commit 00bb1b7ac1
6 changed files with 49 additions and 29 deletions

View File

@@ -42,6 +42,22 @@ ValuesController::ValuesController(Responder * parentResponder, InputEventHandle
m_selectableTableView.setDelegate(this);
}
KDCoordinate ValuesController::columnWidth(int i) {
ContinuousFunction::PlotType plotType = plotTypeAtColumn(&i);
if (i > 0 && plotType == ContinuousFunction::PlotType::Parametric) {
return 2*k_cellWidth;
}
return k_cellWidth;
}
KDCoordinate ValuesController::cumulatedWidthFromIndex(int i) {
return TableViewDataSource::cumulatedWidthFromIndex(i);
}
int ValuesController::indexFromCumulatedWidth(KDCoordinate offsetX) {
return TableViewDataSource::indexFromCumulatedWidth(offsetX);
}
Shared::Hideable * ValuesController::hideableCellFromType(HighlightCell * cell, int type) {
if (type == k_notEditableValueCellType) {
Shared::HideableEvenOddBufferTextCell * myCell = static_cast<Shared::HideableEvenOddBufferTextCell *>(cell);