Rounded earn values from overview to two decimal digits.
This commit is contained in:
@@ -43,7 +43,7 @@ void ChartRulersView::setChartData(
|
||||
return FormatF(value / float64(Data::kEarnMultiplier));
|
||||
};
|
||||
_rightCustomCaption = [=, rate = chartData.currencyRate](float64 v) {
|
||||
return Info::ChannelEarn::ToUsd(v, rate);
|
||||
return Info::ChannelEarn::ToUsd(v, rate, 0);
|
||||
};
|
||||
_rightPen = QPen(st::windowSubTextFg);
|
||||
}
|
||||
|
||||
@@ -186,7 +186,10 @@ PointDetailsWidget::PointDetailsWidget(
|
||||
QString::number(value / multiplier));
|
||||
const auto usdText = Ui::Text::String(
|
||||
_textStyle,
|
||||
Info::ChannelEarn::ToUsd(value, _chartData.currencyRate));
|
||||
Info::ChannelEarn::ToUsd(
|
||||
value,
|
||||
_chartData.currencyRate,
|
||||
0));
|
||||
const auto width = std::max(
|
||||
usdText.maxWidth(),
|
||||
valueText.maxWidth());
|
||||
@@ -351,7 +354,7 @@ void PointDetailsWidget::setXIndex(int xIndex) {
|
||||
_textStyle,
|
||||
Info::ChannelEarn::ToUsd(
|
||||
dataLine.y[xIndex],
|
||||
_chartData.currencyRate));
|
||||
_chartData.currencyRate, 0));
|
||||
}
|
||||
_lines.push_back(std::move(textLine));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user