Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F3245797
D6494.id21980.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Referenced Files
None
Subscribers
None
D6494.id21980.diff
View Options
diff --git a/native/media/media-gallery-media.react.js b/native/media/media-gallery-media.react.js
--- a/native/media/media-gallery-media.react.js
+++ b/native/media/media-gallery-media.react.js
@@ -87,6 +87,28 @@
return props.isFocused || props.isQueued;
}
+ componentDidMount() {
+ const isActive = MediaGalleryMedia.isActive(this.props);
+ if (isActive) {
+ // eslint-disable-next-line import/no-named-as-default-member
+ Reanimated.timing(this.focusProgress, {
+ ...reanimatedSpec,
+ toValue: 1,
+ }).start();
+ }
+
+ if (this.props.isQueued) {
+ // When I updated to React Native 0.60, I also updated Lottie. At that
+ // time, on iOS the last frame of the animation drops the circle outlining
+ // the checkmark. This is a hack to get around that
+ const maxValue = Platform.OS === 'ios' ? 0.99 : 1;
+ Animated.timing(this.checkProgress, {
+ ...animatedSpec,
+ toValue: maxValue,
+ }).start();
+ }
+ }
+
componentDidUpdate(prevProps: Props) {
const isActive = MediaGalleryMedia.isActive(this.props);
const wasActive = MediaGalleryMedia.isActive(prevProps);
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Fri, Nov 15, 8:20 PM (21 h, 56 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2495327
Default Alt Text
D6494.id21980.diff (1 KB)
Attached To
Mode
D6494: [native] Allow MediaGallery items to mount pre-selected
Attached
Detach File
Event Timeline
Log In to Comment