titansgroup / k4l-video-trimmer

A library with UI and mechanisms to trim local videos on Android applications.
MIT License
783 stars 220 forks source link

CancelClicked should call VideoView.stopPlayback #9

Closed gouravd closed 8 years ago

gouravd commented 8 years ago

I think cancelClicked should do a bit of cleanup 1) stop VideoView playback

Also it would be helpful if VideoView is exposed so that we can control some other aspects like its visibility etc..

In my use case the Trimmer is housed in a RelativeLayout and stays hidden. When required we make the RelLayout visible and set URI. But if we click cancel, there is no way to stop the video and hide the videoView. Hiding the Relativelayout does not help because our background is a GLSurfaceView and the Zorder thing messes things up.

Currently I have edited the Trimmer to make VideoView visible on setURI and stop playback & invisible on CancelClicked

dogo commented 8 years ago

Yep! Thanks @gouravd the cancel action should stop the video playback, about expose some other aspects would be nice, you can open a PR proposing those changes