2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-09-01 06:55:58 +00:00

Use Storage::Cache::Database for file caching.

This commit is contained in:
John Preston
2018-08-27 14:35:58 +03:00
parent a58c082cfa
commit 2e7f4c2f21
30 changed files with 537 additions and 888 deletions

View File

@@ -863,7 +863,7 @@ void Document::paint(Painter &p, const QRect &clip, TextSelection selection, con
bool selected = (selection == FullSelection);
_data->automaticLoad(parent()->fullId(), parent());
bool loaded = _data->loaded() || Local::willStickerImageLoad(_data->mediaKey()), displayLoading = _data->displayLoading();
bool loaded = _data->loaded(), displayLoading = _data->displayLoading();
if (displayLoading) {
ensureRadial();
@@ -1024,8 +1024,7 @@ void Document::paint(Painter &p, const QRect &clip, TextSelection selection, con
TextState Document::getState(
QPoint point,
StateRequest request) const {
const auto loaded = _data->loaded()
|| Local::willStickerImageLoad(_data->mediaKey());
const auto loaded = _data->loaded();
const auto wthumb = withThumb();
if (_data->isAudioFile()) {