Disable layout animation
This commit is contained in:
parent
4aeda3f778
commit
d42f623a2f
|
@ -10,7 +10,7 @@ import ActivityIndicator from '../../../containers/ActivityIndicator';
|
||||||
import { MessageType, TAnyMessage, TMessageModel, TThreadMessageModel, TThreadModel } from '../../../definitions';
|
import { MessageType, TAnyMessage, TMessageModel, TThreadMessageModel, TThreadModel } from '../../../definitions';
|
||||||
import database from '../../../lib/database';
|
import database from '../../../lib/database';
|
||||||
import { compareServerVersion, debounce } from '../../../lib/methods/helpers';
|
import { compareServerVersion, debounce } from '../../../lib/methods/helpers';
|
||||||
import { animateNextTransition } from '../../../lib/methods/helpers/layoutAnimation';
|
// import { animateNextTransition } from '../../../lib/methods/helpers/layoutAnimation';
|
||||||
import log from '../../../lib/methods/helpers/log';
|
import log from '../../../lib/methods/helpers/log';
|
||||||
import EmptyRoom from '../EmptyRoom';
|
import EmptyRoom from '../EmptyRoom';
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
|
@ -148,7 +148,7 @@ class ListContainer extends React.Component<IListContainerProps, IListContainerS
|
||||||
|
|
||||||
query = async () => {
|
query = async () => {
|
||||||
this.count += QUERY_SIZE;
|
this.count += QUERY_SIZE;
|
||||||
const { rid, tmid, showMessageInMainThread, serverVersion, listRef } = this.props;
|
const { rid, tmid, showMessageInMainThread, serverVersion } = this.props;
|
||||||
const db = database.active;
|
const db = database.active;
|
||||||
|
|
||||||
// handle servers with version < 3.0.0
|
// handle servers with version < 3.0.0
|
||||||
|
@ -207,10 +207,10 @@ class ListContainer extends React.Component<IListContainerProps, IListContainerS
|
||||||
}
|
}
|
||||||
|
|
||||||
if (this.mounted) {
|
if (this.mounted) {
|
||||||
if (this.animated) {
|
// if (this.animated) {
|
||||||
listRef.current?.prepareForLayoutAnimationRender();
|
// listRef.current?.prepareForLayoutAnimationRender();
|
||||||
animateNextTransition();
|
// animateNextTransition();
|
||||||
}
|
// }
|
||||||
this.setState({ messages: data });
|
this.setState({ messages: data });
|
||||||
} else {
|
} else {
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
|
|
|
@ -22,7 +22,7 @@ import * as HeaderButton from '../../containers/HeaderButton';
|
||||||
import StatusBar from '../../containers/StatusBar';
|
import StatusBar from '../../containers/StatusBar';
|
||||||
import ActivityIndicator from '../../containers/ActivityIndicator';
|
import ActivityIndicator from '../../containers/ActivityIndicator';
|
||||||
import { serverInitAdd } from '../../actions/server';
|
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 { TSupportedThemes, withTheme } from '../../theme';
|
||||||
import EventEmitter from '../../lib/methods/helpers/events';
|
import EventEmitter from '../../lib/methods/helpers/events';
|
||||||
import { themedHeader } from '../../lib/methods/helpers/navigation';
|
import { themedHeader } from '../../lib/methods/helpers/navigation';
|
||||||
|
@ -367,10 +367,10 @@ class RoomsListView extends React.Component<IRoomsListViewProps, IRoomsListViewS
|
||||||
| (Pick<IRoomsListViewState, keyof IRoomsListViewState> | IRoomsListViewState | null),
|
| (Pick<IRoomsListViewState, keyof IRoomsListViewState> | IRoomsListViewState | null),
|
||||||
callback?: () => void
|
callback?: () => void
|
||||||
) => {
|
) => {
|
||||||
if (this.animated) {
|
// if (this.animated) {
|
||||||
this.scroll?.prepareForLayoutAnimationRender();
|
// this.scroll?.prepareForLayoutAnimationRender();
|
||||||
animateNextTransition();
|
// animateNextTransition();
|
||||||
}
|
// }
|
||||||
this.setState(state, callback);
|
this.setState(state, callback);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue