Skip to content
This repository has been archived by the owner on Aug 11, 2020. It is now read-only.

Commit

Permalink
Merge in BlackBerry 10 support
Browse files Browse the repository at this point in the history
  • Loading branch information
timwindsor committed Jul 15, 2015
1 parent cce09e3 commit 6043674
Show file tree
Hide file tree
Showing 2 changed files with 36 additions and 2 deletions.
19 changes: 17 additions & 2 deletions README.md
Expand Up @@ -28,6 +28,7 @@ It is also possible to install via repo url directly ( unstable )
- iOS
- Windows 8
- Windows Phone 8
- BlackBerry 10
- Browser

Note: the Android source for this project includes an Android Library Project.
Expand Down Expand Up @@ -104,6 +105,17 @@ The following barcode types are currently supported:
* AZTEC
* PDF417

### BlackBerry 10
* UPC_A
* UPC_E
* EAN_8
* EAN_13
* CODE_39
* CODE_128
* ITF
* DATA_MATRIX
* AZTEC

`success` and `fail` are callback functions. Success is passed an object with data, type and cancelled properties. Data is the text representation of the barcode data, type is the type of barcode detected and cancelled is whether or not the user cancelled the scan.

A full example could be:
Expand Down Expand Up @@ -149,10 +161,13 @@ Windows 8 implenemtation currently doesn't support encode functionality.
## Windows Phone 8 quirks ##
Windows Phone 8 implenemtation currently doesn't support encode functionality.

## Thanks on Github ##
## BlackBerry 10 quirks
BlackBerry 10 implenematation currently doesn't support encode functionality.

So many -- check out the original [iOS](https://github.com/phonegap/phonegap-plugins/tree/DEPRECATED/iOS/BarcodeScanner) and [Android](https://github.com/phonegap/phonegap-plugins/tree/DEPRECATED/Android/BarcodeScanner) repos.
## Thanks on Github ##

So many -- check out the original [iOS](https://github.com/phonegap/phonegap-plugins/tree/master/iOS/BarcodeScanner), [Android](https://github.com/phonegap/phonegap-plugins/tree/master/Android/BarcodeScanner) and
[BlackBerry 10](https://github.com/umcsdon/WebWorks-Community-APIs/tree/master/BB10-Cordova/BarcodeScanner) repos.

## Licence ##

Expand Down
19 changes: 19 additions & 0 deletions plugin.xml
Expand Up @@ -347,5 +347,24 @@
<runs />
</js-module>
</platform>

<!-- BlackBerry 10 -->
<platform name="blackberry10">
<js-module src="www/blackberry10/client.js" name="BarcodeScanner">
<clobbers target="cordova.plugins.barcodeScanner" />
</js-module>

<source-file src="src/blackberry10/index.js" target-dir="BarcodeScanner" />
<lib-file src="src/blackberry10/native/device/libBarcodeScanner.so" arch="device"/>
<lib-file src="src/blackberry10/native/simulator/libBarcodeScanner.so" arch="simulator"/>
<config-file target="www/config.xml" parent="/widget">
<feature name="BarcodeScanner">
<param name="blackberry-package" value="com.blackberry.community.barcodescanner" />
</feature>
</config-file>
<config-file target="www/config.xml" parent="/widget/rim:permissions">
<rim:permit>use_camera</rim:permit>
</config-file>
<dependency id="com.blackberry.app" />
</platform>
</plugin>

0 comments on commit 6043674

Please sign in to comment.