2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-09-02 07:25:46 +00:00

Use crl::time/now instead of TimeMs/getms.

This commit is contained in:
John Preston
2019-02-19 10:57:53 +04:00
parent d208236994
commit fe618bd652
310 changed files with 1133 additions and 1141 deletions

View File

@@ -72,7 +72,7 @@ public:
, _check(st, _updateCallback) {
}
void paint(Painter &p, TimeMs ms, QPoint position, int outerWidth, bool selected, bool selecting);
void paint(Painter &p, crl::time ms, QPoint position, int outerWidth, bool selected, bool selecting);
void setActive(bool active);
void setPressed(bool pressed);
@@ -93,7 +93,7 @@ private:
};
void Checkbox::paint(Painter &p, TimeMs ms, QPoint position, int outerWidth, bool selected, bool selecting) {
void Checkbox::paint(Painter &p, crl::time ms, QPoint position, int outerWidth, bool selected, bool selecting) {
_check.setDisplayInactive(selecting);
_check.setChecked(selected);
const auto pression = _pression.current(ms, (_active && _pressed) ? 1. : 0.);
@@ -235,7 +235,7 @@ void RadialProgressItem::setLinks(ClickHandlerPtr &&openl, ClickHandlerPtr &&sav
_cancell = std::move(cancell);
}
void RadialProgressItem::step_radial(TimeMs ms, bool timer) {
void RadialProgressItem::step_radial(crl::time ms, bool timer) {
const auto updateRadial = [&] {
return _radial->update(dataProgress(), dataFinished(), ms);
};
@@ -265,7 +265,7 @@ void RadialProgressItem::checkRadialFinished() {
RadialProgressItem::~RadialProgressItem() = default;
void StatusText::update(int newSize, int fullSize, int duration, TimeMs realDuration) {
void StatusText::update(int newSize, int fullSize, int duration, crl::time realDuration) {
setSize(newSize);
if (_size == FileStatusSizeReady) {
_text = (duration >= 0) ? formatDurationAndSizeText(duration, fullSize) : (duration < -1 ? formatGifAndSizeText(fullSize) : formatSizeText(fullSize));