How to prevent from right to left sliding popup window from occuring in process of scanning (Intent)

10 views
Skip to the first unread message

Janne Kalliokulju

unread,
26 May 2016, 08:35:5826/05/2016
to zxing
Hi,

Was wondering if you could help me with one problem I am currently having when using com.google.zxing.client.android.SCAN as an intent. The thing is that I am able to scan the code, I get the scan result back from activity and display it in my Toast element. Everything works ok, but I am not happy with default behaviour how the scanning takes place. I would like to get rid of from right to left sliding popup window displaying some sort of a pre-configured default picture (apparently qr-code) with a text saying "scanning". When the scan is complete & ready, the popup window disappears and the bar/qr code is displayed correctly on my Toast. Is there a way to prevent this sliding popup effect from happening? If yes, then how to do it? I’ve been trying to look for solutions for the problem for longer time, but so far without a success. This is what my intent looks like currently..

Intent intentScan = new Intent("com.google.zxing.client.android.SCAN");
intentScan.addCategory(Intent.CATEGORY_DEFAULT);
intentScan.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);
intentScan.addFlags(Intent.FLAG_ACTIVITY_CLEAR_WHEN_TASK_RESET);
//intentScan.addFlags(Intent.FLAG_ACTIVITY_NO_ANIMATION);

I also tried the Intent.FLAG_ACTIVITY_NO_ANIMATION, but after adding it to my code the whole app stops working meaning that my app is no longer able to scan. Would appreciate if you take your time to see if you could help with the problem? Attached also a picture how the app currently works and on which you can see the disliked behaviour.

Best regards,
Janne
kuva.jpg
Reply all
Reply to author
Forward
0 new messages