Improved process of message repaint on swipe to reply.

This commit is contained in:
23rd 2024-09-03 13:32:17 +03:00 committed by John Preston
parent 3d2af9db8e
commit fb1b845211

View file

@ -383,10 +383,15 @@ HistoryInner::HistoryInner(
_migrated->delegateMixin()->setCurrent(this);
_migrated->translateTo(_history->translatedTo());
}
HistoryView::SetupSwipeHandler(this, _scroll, [=](
HistoryView::SetupSwipeHandler(this, _scroll, [=, history = _history](
HistoryView::ChatPaintGestureHorizontalData data) {
_gestureHorizontal = data;
update();
const auto item = history->peer->owner().message(
history->peer->id,
MsgId{ data.msgBareId });
if (item) {
repaintItem(item);
}
}, [=, show = controller->uiShow()](int cursorTop) {
auto result = HistoryView::SwipeHandlerFinishData();
if (inSelectionMode()) {