2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-09-07 01:45:39 +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

@@ -323,7 +323,7 @@ void MainWindow::workmodeUpdated(DBIWorkMode mode) {
void MainWindow::psUpdateIndicator() {
#ifndef TDESKTOP_DISABLE_GTK_INTEGRATION
_psUpdateIndicatorTimer.stop();
_psLastIndicatorUpdate = getms();
_psLastIndicatorUpdate = crl::now();
QFileInfo iconFile(_trayIconImageFile());
if (iconFile.exists()) {
QByteArray path = QFile::encodeName(iconFile.absoluteFilePath()), name = QFile::encodeName(iconFile.fileName());
@@ -363,7 +363,7 @@ void MainWindow::updateIconCounters() {
if (noQtTrayIcon) {
#ifndef TDESKTOP_DISABLE_GTK_INTEGRATION
if (useAppIndicator) {
if (getms() > _psLastIndicatorUpdate + 1000) {
if (crl::now() > _psLastIndicatorUpdate + 1000) {
psUpdateIndicator();
} else if (!_psUpdateIndicatorTimer.isActive()) {
_psUpdateIndicatorTimer.start(100);