@scrumble-nl/react-native-honeywell-scanner 1.0.69 → 1.0.71

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -88,7 +88,7 @@ public class HoneywellScannerModule extends ReactContextBaseJavaModule implement
88
88
  /*******************************/
89
89
 
90
90
  @ReactMethod
91
- public void startReader() {
91
+ public void startReader(Callback callBack) {
92
92
  AidcManager.create(reactContext, new CreatedCallback() {
93
93
  @Override
94
94
  public void onCreated(AidcManager aidcManager) {
@@ -100,7 +100,7 @@ public class HoneywellScannerModule extends ReactContextBaseJavaModule implement
100
100
  public void onBarcodeDeviceConnectionEvent(BarcodeDeviceConnectionEvent event) {
101
101
  String connected;
102
102
 
103
- if (event.getConnectionStatus() == manager.BARCODE.DEVICE.DISCONNECTED) {
103
+ if (event.getConnectionStatus() == manager.BARCODE_DEVICE_DISCONNECTED) {
104
104
  connected = "Disconnected";
105
105
  } else {
106
106
  connected = "Connected";
@@ -108,7 +108,7 @@ public class HoneywellScannerModule extends ReactContextBaseJavaModule implement
108
108
 
109
109
  final String message = "Scanner: " + event.getBarcodeReaderInfo().getName() + " is " + connected;
110
110
 
111
- Toast.makeText(reactContext, message, Toast.LENGTH_LONG).show();
111
+ callBack.invoke(message);
112
112
  }
113
113
  });
114
114
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@scrumble-nl/react-native-honeywell-scanner",
3
3
  "title": "React Native Honeywell Scanner-v2",
4
- "version": "1.0.69",
4
+ "version": "1.0.71",
5
5
  "description": "Bridge to use the Honeywell scanner",
6
6
  "main": "dist/index.js",
7
7
  "types": "dist/index.d.ts",