UI Controls Become Selected Upon Scan

I developed an Android application that scans barcodes using Intents. The application uses the EMDK library with an associated Profile in DataWedge. The target hardware is a TC70. The application works in that I can scan barcodes and put the data to a ListView.

 

The problem I'm having is that when I trigger a scan using the device's button, the first element in the activity_main gets selected. So for example, I have Menu options. When I push the scan button on the scanner, the options menu becomes selected and the first menu option is displayed. 

 

If I put a Button above the Listview and scan something, the Button (that's above the Listview) is then selected. I have no idea why this is happening.