mirror of
https://github.com/element-hq/element-web
synced 2024-11-24 18:25:49 +03:00
Merge pull request #1656 from matrix-org/luke/fix-scroll-jump-on-message-decryption
Fix one variant of a scroll jump that occurs when decrypting an m.text
This commit is contained in:
commit
d2066f41d5
1 changed files with 5 additions and 0 deletions
|
@ -196,6 +196,8 @@ module.exports = withMatrixClient(React.createClass({
|
|||
*/
|
||||
_onDecrypted: function() {
|
||||
// we need to re-verify the sending device.
|
||||
// (we call onWidgetLoad in _verifyEvent to handle the case where decryption
|
||||
// has caused a change in size of the event tile)
|
||||
this._verifyEvent(this.props.mxEvent);
|
||||
this.forceUpdate();
|
||||
},
|
||||
|
@ -214,6 +216,9 @@ module.exports = withMatrixClient(React.createClass({
|
|||
const verified = await this.props.matrixClient.isEventSenderVerified(mxEvent);
|
||||
this.setState({
|
||||
verified: verified,
|
||||
}, () => {
|
||||
// Decryption may have caused a change in size
|
||||
this.props.onWidgetLoad();
|
||||
});
|
||||
},
|
||||
|
||||
|
|
Loading…
Reference in a new issue