@captureid/capacitor-cidprint 5.0.62 → 5.0.63
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.
|
@@ -787,6 +787,9 @@ public class CIDPrint extends Plugin {
|
|
|
787
787
|
case NOTIFY:
|
|
788
788
|
handleNotification(event);
|
|
789
789
|
break;
|
|
790
|
+
case UPDATE:
|
|
791
|
+
handleUpdate(event);
|
|
792
|
+
break;
|
|
790
793
|
}
|
|
791
794
|
}
|
|
792
795
|
|
|
@@ -851,6 +854,12 @@ public class CIDPrint extends Plugin {
|
|
|
851
854
|
notifyListeners(LIBRARY_EVENT, obj);
|
|
852
855
|
}
|
|
853
856
|
|
|
857
|
+
private void handleUpdate(PrinterLibraryEvent evt) {
|
|
858
|
+
JSObject obj = new JSObject();
|
|
859
|
+
obj = fromJSONObject(evt.toJSONObject());
|
|
860
|
+
notifyListeners(LIBRARY_EVENT, obj);
|
|
861
|
+
}
|
|
862
|
+
|
|
854
863
|
private void addCallback(String functionName, PluginCall callback) {
|
|
855
864
|
try {
|
|
856
865
|
if (_callbacks.containsKey(functionName)) {
|