Giter VIP home page Giter VIP logo

Comments (7)

KingsMentor avatar KingsMentor commented on July 20, 2024

@oumardiarra you can achieve this by

barcodeCapture.setTouchAsCallback(false);

from mobilevisionbarcodescanner.

oumardiarra avatar oumardiarra commented on July 20, 2024

Hi @KingsMentor
thanks for the feedback. Where tu put that code. I've added it to the oncreate method like this:

protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main2); BarcodeCapture barcodeCapture = (BarcodeCapture) getSupportFragmentManager().findFragmentById(R.id.barcode); barcodeCapture.setTouchAsCallback(false); barcodeCapture.setRetrieval(this); /* barcodeCapture.setTouchAsCallback(false);*/ }
and I'm still getting value when I only click on screen. Also I've added barcodeCapture.setShowFlash(true);
after barcode initialization but it doesn't work. Flash works only if i use it directly in fragment(app:gvb_flash="true)

from mobilevisionbarcodescanner.

KingsMentor avatar KingsMentor commented on July 20, 2024

@oumardiarra don't forget to call :

barcodeCapture.refresh(true);

call that method after changing any of the barcode preferences to make sure changes is reflected.
Let me know if this resolved the issue.

from mobilevisionbarcodescanner.

oumardiarra avatar oumardiarra commented on July 20, 2024

@KingsMentor no, I don't have the ability to add boolean parameter to the refresh() method.
Only barcodeCapture.refresh(); and also using it , I have the same behavior. Do i have to call it before calling barcodeCapture.setRetrieval(this); or after?
Though I have tested both with same result. Seems that only Attributes on fragments works in my case but I don't have setTouchAsCallback on it.

from mobilevisionbarcodescanner.

KingsMentor avatar KingsMentor commented on July 20, 2024

@oumardiarra update your dependency to :

compile 'xyz.belvi.mobilevision:barcodescanner:2.0.3'

// forceUpdate can be true or false
Also, call barcodeCapture.refresh(forceUpdate); only after changing the barcode properties.

from mobilevisionbarcodescanner.

KingsMentor avatar KingsMentor commented on July 20, 2024

@oumardiarra confirm if the issue has been resolved.

from mobilevisionbarcodescanner.

oumardiarra avatar oumardiarra commented on July 20, 2024

@KingsMentor sorry for the delay. I always get values only when i click on screeen. I've updated my dependency as suggested above. Here is the code:

barcodeCapture.setSupportMultipleScan(true); barcodeCapture.setShowDrawRect(true); barcodeCapture.setTouchAsCallback(false); barcodeCapture.refresh(true);

from mobilevisionbarcodescanner.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.