mirror of https://github.com/procxx/kepka.git
Fix block chat list loading by date.
This commit is contained in:
parent
be64f18e96
commit
db35c3de3b
|
@ -776,13 +776,11 @@ void ApiWrap::requestMoreDialogs(Data::Folder *folder) {
|
||||||
});
|
});
|
||||||
|
|
||||||
if (!folder) {
|
if (!folder) {
|
||||||
requestDialogs(folder);
|
if (!_dialogsLoadState || !_dialogsLoadState->listReceived) {
|
||||||
requestContacts();
|
|
||||||
if (!_dialogsLoadState
|
|
||||||
|| (!_dialogsLoadState->listReceived
|
|
||||||
&& !_dialogsLoadState->requestId)) {
|
|
||||||
refreshDialogsLoadBlocked();
|
refreshDialogsLoadBlocked();
|
||||||
}
|
}
|
||||||
|
requestDialogs(folder);
|
||||||
|
requestContacts();
|
||||||
}
|
}
|
||||||
_session->data().chatsListChanged(folder);
|
_session->data().chatsListChanged(folder);
|
||||||
}).fail([=](const RPCError &error) {
|
}).fail([=](const RPCError &error) {
|
||||||
|
@ -923,6 +921,7 @@ void ApiWrap::requestMoreBlockedByDateDialogs() {
|
||||||
_dialogsLoadTill = _dialogsLoadState->offsetDate
|
_dialogsLoadTill = _dialogsLoadState->offsetDate
|
||||||
? (_dialogsLoadState->offsetDate - max)
|
? (_dialogsLoadState->offsetDate - max)
|
||||||
: (unixtime() - max);
|
: (unixtime() - max);
|
||||||
|
refreshDialogsLoadBlocked();
|
||||||
requestDialogs();
|
requestDialogs();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -671,6 +671,7 @@ void Widget::refreshLoadMoreButton(bool mayBlock, bool isBlocked) {
|
||||||
st::dialogsLoadMoreButton,
|
st::dialogsLoadMoreButton,
|
||||||
st::dialogsLoadMore,
|
st::dialogsLoadMore,
|
||||||
st::dialogsLoadMore);
|
st::dialogsLoadMore);
|
||||||
|
_loadMoreChats->show();
|
||||||
_loadMoreChats->addClickHandler([=] {
|
_loadMoreChats->addClickHandler([=] {
|
||||||
loadMoreBlockedByDate();
|
loadMoreBlockedByDate();
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in New Issue