Skip to content

Commit

Permalink
fix: fail dialog keeps showing if start trimming right after enter sc…
Browse files Browse the repository at this point in the history
…reen
  • Loading branch information
maitrungduc1410 committed Oct 16, 2024
1 parent 82e9252 commit cd2d872
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -266,8 +266,6 @@ private void mediaPrepared() {
VideoTrimmerUtil.MAX_COUNT_RANGE = Math.max((VIDEO_FRAMES_WIDTH / VideoTrimmerUtil.mThumbWidth), VideoTrimmerUtil.MAX_COUNT_RANGE);

startShootVideoThumbs(mContext, VideoTrimmerUtil.MAX_COUNT_RANGE, 0, mDuration);
} else {

}

// Set initial handle positions if mMaxDuration < video duration
Expand Down Expand Up @@ -348,7 +346,9 @@ private void playOrPause() {

public void onMediaPause() {
mTimingHandler.removeCallbacks(mTimingRunnable);
mediaPlayer.pause();
if (mediaPlayer.isPlaying()) {
mediaPlayer.pause();
}
setPlayPauseViewIcon(false);
}

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "react-native-video-trim",
"version": "2.2.8",
"version": "2.2.9",
"description": "Video trimmer for your React Native app",
"main": "lib/commonjs/index",
"module": "lib/module/index",
Expand Down

0 comments on commit cd2d872

Please sign in to comment.