mirror of
https://github.com/UpsilonNumworks/Upsilon.git
synced 2026-01-19 00:37:25 +01:00
[apps/probability] For discrete law, round calculation parameters to the
closest integer Change-Id: I53dcc0605ae91ed27257fa4b831ce8a2287db3ef
This commit is contained in:
@@ -227,6 +227,9 @@ bool CalculationController::textFieldDidFinishEditing(TextField * textField, con
|
||||
floatBody = 1.0f;
|
||||
}
|
||||
}
|
||||
if (!m_law->isContinuous() && (m_highlightedSubviewIndex == 1 || m_calculation->type() == Calculation::Type::FiniteIntegral)) {
|
||||
floatBody = roundf(floatBody);
|
||||
}
|
||||
m_calculation->setParameterAtIndex(floatBody, m_highlightedSubviewIndex-1);
|
||||
for (int k = 0; k < m_calculation->numberOfParameters(); k++) {
|
||||
m_contentView.willDisplayEditableCellAtIndex(k);
|
||||
|
||||
Reference in New Issue
Block a user