2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-08-31 06:26:18 +00:00

new layout items structure started

This commit is contained in:
John Preston
2015-12-20 17:05:07 +03:00
parent 7d8c45ec92
commit cc004d435b
18 changed files with 1056 additions and 389 deletions

View File

@@ -110,6 +110,8 @@ public slots:
private:
MsgId complexMsgId(const HistoryItem *item) const;
bool itemMigrated(MsgId msgId) const;
ChannelId itemChannel(MsgId msgId) const;
MsgId itemMsgId(MsgId msgId) const;
@@ -185,7 +187,7 @@ private:
FlatInput _search;
IconedButton _cancelSearch;
QVector<MsgId> _results;
int32 _itemsToBeLoaded;
int32 _cachedItemsToBeLoaded;
QTimer _searchTimer;
QString _searchQuery;
@@ -211,6 +213,9 @@ private:
CachedLink *cachedLink(HistoryItem *item);
typedef QVector<LayoutItem*> Items;
Items _items;
// other
struct CachedItem {
CachedItem() : msgid(0), y(0), link(0) {
@@ -223,7 +228,7 @@ private:
CachedLink *link;
};
typedef QVector<CachedItem> CachedItems;
CachedItems _items;
CachedItems _cachedItems;
int32 _width, _height, _minHeight, _addToY;