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

Camera still capturing after navigtion - NS6 with Angular #138

Open
ghost opened this issue Oct 27, 2020 · 2 comments
Open

Camera still capturing after navigtion - NS6 with Angular #138

ghost opened this issue Oct 27, 2020 · 2 comments

Comments

@ghost
Copy link

ghost commented Oct 27, 2020

Hi,
I'm using Nativescript 6.5.3 with Angular,
After navigation to other page, the camera is still capturing,
If I go back via page.frame.goBack() the camera indeed stopping,
actually I noticed it thanks to IOS 14 which show a small dot when camera is on, So I tried to download
https://play.google.com/store/apps/details?id=you.in.spark.access.dots
and saw the problem happens in Android too,

How can I release the camera ?

Thanks !

@kriefsacha
Copy link

Did you find a solution @Arturiko ?

@arturikoX
Copy link

Did you find a solution @Arturiko ?

Hi,
I did :
this._page.on(Page.unloadedEvent, () => { this.isCapturing = false; this.cam.disposeNativeView(); });

When cam is:

camLoaded(e: any): void { this.cam = e.object as CameraPlus; ... }

I think disposeNativeView is the secret..

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

2 participants