HomePhabricator
Diffusion Comm 201e05a269b8

[native] Avoid transition delay during upload

Description

[native] Avoid transition delay during upload

Summary:
Fixes ENG-3615. I discovered that the problem was in our departing vs current source logic in multimedia.react.js. Both sources caused onLoad to be triggered. Because departing source is usually local URI, it was loaded much faster, triggered onLoad which removed itself way before the current source was actually loaded.

Added boolean to indicate that onLoad should not be triggered for departing source.

Depends on D7765

Test Plan: Artifically disabled cache and delayed decryption in encrypted-image.react.js and sent an encrypted photo. The local image was displayed instead of a spinner until decryption finishes. After leaving and re-entering the thread, the spinner was displayed until the image was decrypted.

Reviewers: ashoat, atul

Reviewed By: ashoat

Subscribers: tomek

Differential Revision: https://phab.comm.dev/D7782

Details

Provenance
bartekAuthored on May 10 2023, 7:29 AM
Reviewer
ashoat
Differential Revision
D7782: [native] Avoid transition delay during upload
Parents
rCOMMb8b133037c37: [native] Add thumbhash step to media mission
Branches
Unknown
Tags
Unknown