From 2cefe12a911dd074a1cd286d7b244a7cd22d6820 Mon Sep 17 00:00:00 2001 From: Diego Mello Date: Wed, 30 Nov 2022 13:07:00 -0300 Subject: [PATCH] Enable layout animation on RoomsListView --- app/views/RoomsListView/index.tsx | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/app/views/RoomsListView/index.tsx b/app/views/RoomsListView/index.tsx index 6f282fcb1..98549081c 100644 --- a/app/views/RoomsListView/index.tsx +++ b/app/views/RoomsListView/index.tsx @@ -22,7 +22,7 @@ import * as HeaderButton from '../../containers/HeaderButton'; import StatusBar from '../../containers/StatusBar'; import ActivityIndicator from '../../containers/ActivityIndicator'; import { serverInitAdd } from '../../actions/server'; -// import { animateNextTransition } from '../../lib/methods/helpers/layoutAnimation'; +import { animateNextTransition } from '../../lib/methods/helpers/layoutAnimation'; import { TSupportedThemes, withTheme } from '../../theme'; import EventEmitter from '../../lib/methods/helpers/events'; import { themedHeader } from '../../lib/methods/helpers/navigation'; @@ -367,11 +367,11 @@ class RoomsListView extends React.Component | IRoomsListViewState | null), callback?: () => void ) => { - // if (this.animated) { - // this.scroll?.prepareForLayoutAnimationRender(); - // animateNextTransition(); - // } this.setState(state, callback); + if (this.animated) { + this.scroll?.prepareForLayoutAnimationRender(); + animateNextTransition(); + } }; addRoomsGroup = (data: ISubscription[], header: string, allData: ISubscription[]) => {