Skip to content
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

confirmStopRecording does not work with Android Hardware Back Button #30

Closed
sagrawal31 opened this issue Mar 10, 2020 · 16 comments
Closed

Comments

@sagrawal31
Copy link

Apologies, if I'm creating so many issues 😞 but I was hoping that the issues that I'm creating should not be there.

Basically, in Android, when recording is started, a student (primary user of our app) might accidentally press the hardware back button. When we encountered the issue, I went looking for the configuration and the doc and found out the method confirmStopRecording(true).

Unfortunately, this shows the confirmation dialogue only for "Stop button" or "Send & Close" checkmark but not when the back button is pressed.

I think this is a very important point when it comes to recorder because the probability of pressing the back button is very high and we can't allow the recorder to be immediately closed without confirmation.

Please let me know how to handle this scenario?

@3akat
Copy link
Contributor

3akat commented Mar 10, 2020

Hi @sagrawal31,
No worries and thank you for reporting issues and suggestions :)
Our goal is to have bug-free SDK which fits all needs of our customers.

Regarding the confirmation when back button is pressed - I'll add this feature.

@sagrawal31
Copy link
Author

Thank you @3akat I hope that will not take much of your time as you will have to probably reuse your existing code. By the way, by when can we expect this?

@3akat
Copy link
Contributor

3akat commented Mar 10, 2020

Plan to release this tomorrow.

@sagrawal31
Copy link
Author

So relieved to see your reply 👍

@3akat
Copy link
Contributor

3akat commented Mar 11, 2020

Hi @sagrawal31! Please take a look at 0.82.5.
FYI: in Android it is not possible to handle press on the rest two buttons (Home and Overview), so if a user will press them during recording there will be now confirmation popup.

@sagrawal31
Copy link
Author

Hi, @3akat thank you for releasing the new version. I'll try that out.

Regarding the rest two buttons, we have already handled it by pinning the app using Android pin feature 😄Thank you for pointing it out explicitly.

@sagrawal31
Copy link
Author

Hi, @3akat I tested the release 0.82.5 and looks like it is working fine. So this can be closed. Although, I have a related concern. Maybe we can create a separate issue for this.

Basically, setting .sendImmediately(false) shows two buttons:

  1. "Stop & close button" which gives options to preview, re-record and submit recording.
  2. "Send & close" check button which directly submits the recording.

But conceptually, sendImmediately should not mix two concerns. Am I making sense?

Also, what if we don't need the first button i.e. we can't allow our user to review their recording and re-record the option. So is there a way we can hide the first button and keep showing the 2nd button when sendImmediately is set to false?

@sagrawal31
Copy link
Author

Hi @3akat let me know if I should create a separate issue for the above?

@3akat
Copy link
Contributor

3akat commented Mar 11, 2020

Hi @sagrawal31,
Yes, please. It looks like feature related discussion, so it's better to move it to a separate issue :)
Thank you!

@sagrawal31
Copy link
Author

Thank you, @3akat. Created #32

@sagrawal31
Copy link
Author

Actually, I noticed a potential UX issue after this issue was fixed.

Basically, in both the cases, when either the hardware back button is pressed or checkmark button is pressed, the message is Are you sure want to stop recording? which is shown in the confirmation dialogue.

But the actions of both the dialogues are different.

  • For the checkmark button, when "OK" is pressed in the confirmation dialogue, the video recording is stopped and video is submitted to the server.
  • For the Android back button, when "OK" is pressed in the confirmation dialogue, the video recording is stopped but video is not submitted to the server.

Of course, the actions are correct but the message is very confusing.

@sagrawal31
Copy link
Author

Can we reopen this issue to discuss?

@Bane-D
Copy link
Contributor

Bane-D commented Mar 17, 2020

Thank you for commenting on this. It can be a bit confusing in such case. Unless my colleague thinks or suggests otherwise, we could:

  1. Checkmark option > "End recording and submit the video?"
  2. Back button > "Are you sure you want to cancel recording?"

In such case there would not be any difference in the actions they do, just the way it is messaged back to the person doing the recording.

Shashank I think these would do nicely however since you reported it happy to hear your suggestion :)

@sagrawal31
Copy link
Author

I agree with you on the texts @Bane-D

Yes, action will be the same.

@sagrawal31
Copy link
Author

@Bane-D would you mind reopening the issue? So that this can be scheduled.

@3akat
Copy link
Contributor

3akat commented Mar 18, 2020

  1. Checkmark option > "End recording and submit the video?"
  2. Back button > "Are you sure you want to cancel recording?"

Good idea, will implement.

@3akat 3akat reopened this Mar 18, 2020
@Bane-D Bane-D closed this as completed May 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants