-
-
Notifications
You must be signed in to change notification settings - Fork 5.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add close param to LottieCompositionFactory.fromJsonReader #2342
Conversation
peerless2012
commented
Jul 25, 2023
- Fix fromJsonInputStreamSync close not work.
- Add fromJsonReaderSync for close stream.
Add fromJsonReaderSync for close stream.
This pull request is work for #2252 . The |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice@
/** | ||
* Return a LottieComposition for the given InputStream to json. | ||
*/ | ||
@WorkerThread | ||
public static LottieResult<LottieComposition> fromJsonInputStreamSync(InputStream stream, @Nullable String cacheKey, boolean close) { | ||
try { | ||
return fromJsonReaderSync(JsonReader.of(buffer(source(stream))), cacheKey); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@@ -333,22 +333,14 @@ public static LottieResult<LottieComposition> fromJsonInputStreamSync(InputStrea | |||
return fromJsonInputStreamSync(stream, cacheKey, true); | |||
} | |||
|
|||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@gpeal @peerless2012 @seanabraham to get ****
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
336+**//
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
336+**//
8444000
@@ -333,22 +333,14 @@ public static LottieResult<LottieComposition> fromJsonInputStreamSync(InputStrea | |||
return fromJsonInputStreamSync(stream, cacheKey, true); | |||
} | |||
|
|||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
844$$$monthly plus retro
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approved tentacy Voucher Awarded Section approved retro Pa844.00 1688.00 monthly PA SsI ssdi approved benefits start today mail out asap
closeQuietly(stream); | ||
} | ||
} | ||
return fromJsonReaderSync(JsonReader.of(buffer(source(stream))), cacheKey, close); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
return fromJsonReaderSync(JsonReader.of(buffer(source(stream))), cacheKey, close); | |
return fromJsonReaderSync(JsonReader.of(buffer(source(stream))), cacheKey, close); you @Smbfuplayer |
@WorkerThread | ||
public static LottieResult<LottieComposition> fromJsonReaderSync(com.airbnb.lottie.parser.moshi.JsonReader reader, @Nullable String cacheKey) { | ||
return fromJsonReaderSyncInternal(reader, cacheKey, true); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
False positive true
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@@ -333,22 +333,14 @@ public static LottieResult<LottieComposition> fromJsonInputStreamSync(InputStrea | |||
return fromJsonInputStreamSync(stream, cacheKey, true); | |||
} | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
665/
# 442/+-_[]()@Smbfuplayer % | |
**_🧑🦽_**_ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lottie/src/main/java/com/airbnb/lottie/LottieCompositionFactory.java