[poincare] Redesign Float::convertTotext

Change-Id: Id27d9472147b5e443ee296feca891392fad735c8
This commit is contained in:
Émilie Feral
2017-01-11 16:07:58 +01:00
parent 245400015f
commit a74eef903a
23 changed files with 136 additions and 95 deletions

View File

@@ -26,8 +26,8 @@ int FloatParameterController::activeCell() {
void FloatParameterController::willDisplayCellForIndex(TableViewCell * cell, int index) {
EditableTextMenuListCell * myCell = (EditableTextMenuListCell *) cell;
char buffer[Constant::FloatBufferSizeInScientificMode];
Float(parameterAtIndex(index)).convertFloatToText(buffer, Constant::FloatBufferSizeInScientificMode, Constant::NumberOfDigitsInMantissaInScientificMode);
char buffer[Float::bufferSizeForFloatsWithPrecision(Constant::LargeNumberOfSignificantDigits)];
Float(parameterAtIndex(index)).convertFloatToText(buffer, Float::bufferSizeForFloatsWithPrecision(Constant::LargeNumberOfSignificantDigits), Constant::LargeNumberOfSignificantDigits);
myCell->setAccessoryText(buffer);
}