2
0
mirror of https://github.com/kotatogram/kotatogram-desktop synced 2025-09-05 09:05:14 +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

@@ -40,7 +40,7 @@ public:
int left,
int top,
int outerWidth,
TimeMs ms) override;
crl::time ms) override;
QImage prepareRippleMask() const override;
bool checkRippleStartPosition(QPoint position) const override;
@@ -242,7 +242,7 @@ void ServiceCheck::paint(
int left,
int top,
int outerWidth,
TimeMs ms) {
crl::time ms) {
Frames().paintFrame(
p,
left + _st.margin.left(),
@@ -496,7 +496,7 @@ void BackgroundPreviewBox::share() {
void BackgroundPreviewBox::paintEvent(QPaintEvent *e) {
Painter p(this);
const auto ms = getms();
const auto ms = crl::now();
const auto color = _paper.backgroundColor();
if (color) {
p.fillRect(e->rect(), *color);
@@ -516,7 +516,7 @@ void BackgroundPreviewBox::paintEvent(QPaintEvent *e) {
paintTexts(p, ms);
}
void BackgroundPreviewBox::paintImage(Painter &p, TimeMs ms) {
void BackgroundPreviewBox::paintImage(Painter &p, crl::time ms) {
Expects(!_scaled.isNull());
const auto master = _paper.isPattern()
@@ -544,7 +544,7 @@ void BackgroundPreviewBox::paintImage(Painter &p, TimeMs ms) {
checkBlurAnimationStart();
}
void BackgroundPreviewBox::paintRadial(Painter &p, TimeMs ms) {
void BackgroundPreviewBox::paintRadial(Painter &p, crl::time ms) {
bool radial = false;
float64 radialOpacity = 0;
if (_radial.animating()) {
@@ -588,7 +588,7 @@ QRect BackgroundPreviewBox::radialRect() const {
st::radialSize);
}
void BackgroundPreviewBox::paintTexts(Painter &p, TimeMs ms) {
void BackgroundPreviewBox::paintTexts(Painter &p, crl::time ms) {
const auto height1 = _text1->height();
const auto height2 = _text2->height();
p.translate(0, textsTop());
@@ -619,7 +619,7 @@ void BackgroundPreviewBox::paintDate(Painter &p) {
p.drawText(bubbleLeft + st::msgServicePadding.left(), bubbleTop + st::msgServicePadding.top() + st::msgServiceFont->ascent, text);
}
void BackgroundPreviewBox::step_radial(TimeMs ms, bool timer) {
void BackgroundPreviewBox::step_radial(crl::time ms, bool timer) {
Expects(_paper.document() != nullptr);
const auto document = _paper.document();
@@ -716,7 +716,7 @@ void BackgroundPreviewBox::checkLoadedDocument() {
guard = std::move(right)
]() mutable {
auto scaled = PrepareScaledFromFull(image, patternBackground);
const auto ms = getms();
const auto ms = crl::now();
auto blurred = patternBackground
? QImage()
: PrepareScaledNonPattern(
@@ -782,9 +782,9 @@ void BackgroundPreviewBox::elementAnimationAutoplayAsync(
not_null<const Element*> element) {
}
TimeMs BackgroundPreviewBox::elementHighlightTime(
crl::time BackgroundPreviewBox::elementHighlightTime(
not_null<const Element*> element) {
return TimeMs();
return crl::time();
}
bool BackgroundPreviewBox::elementInSelectionMode() {