-
Notifications
You must be signed in to change notification settings - Fork 38
Supporting a plugin
jxp edited this page Mar 16, 2012
·
3 revisions
Adding support for a PhoneGap plugin should be very easy.
- Inspect the plugin javascript to determine what methods it has and what data (if any) it returns.
- Create a json file containing sample data for the plugin methods
- Create a substitute javascript file for the plugin
Load the json data into phonegapdesktop using parseConfigFile
Implement all the api methods using randomException (when appropriate), getDebugValue (to read json data) or intervalFunction for methods that repeat on an interval
See the barcode scanner plugin example in the source.