androidflutterdartdatawedge

Does flutter change incoming Android Intents?


I am writing a Flutter app that listens for barcode scans via Zebra's Datawedge service. I have the service configured that it launches an Android Intent with the barcode information.

I am able to successfully register a broadcast receiver, and I know that I am receiving the broadcasts when I scan. The problem however is that for some reason the Intent action is not the same as what I have registered. I have never run into this problem working with Datawedge in Android Studio, and my profile is identical to any other project.

Every time I scan I receive an Intent with the action android.intent.action.RUN, and the extras Bundle[{enable-checked-mode=true, start-paused=true, enable-dart-profiling=true, verify-entry-points=true, enable-background-compilation=true}]

My question is, does Dart or Flutter obscure incoming Android Intents in some way? I've also tried registering my action/category in the AndroidManifest, and that has also not worked, I am still getting the same intent.


Solution

  • My mistake here was using an anonymous BroadcastReceiver object. Once I refactored that into a full class and created an instance of it, then it worked just fine.