java - Phonegap 3.6 Custom Plugin -


I put a plugin for an app with PhoneGap 1.9 a few hours ago and it worked perfectly. The plugin basically opens the user's phonebook and gives details of the user's contact details to my app.

I have recently upgraded to PhoneGAP 3.6 and I am trying to convert my plugin to 3.6; Although I can not get the plugin to work now, it is all 3.6. What do I have here ...

main_activity_starter.js

  property / www / lib / js / main_activity_starter.js var MainActivityStarter = function () {}; MainActivityStarter.prototype.start = function () {cordova.acac (tap, tap, 'main activity starter', 'start', []); }; MainActivityStarter.prototype.goGoogleApp = Function (Acer) {console.log ("GMAP addr:" + addr); Cordova.XACC (Tap, Faucet, 'Main ActiveStarter', 'GoAge App', [Eder]); }; Cordova.addConstructor (function () {cordova.addPlugin ('main activator', new main activity starter);});    Private callback callback callback; / ** * * * @ Param Action * Aquacute's Action * Arguments for Plugin @Param Args JSONArray * @ Ultimate Callback IDP Caller ID when Calling Back in Javascript * @ Return a plugin and a message * * Perform results object with plugins / public (string action, jsonarra rgr, string callback id) {plugin result result = new plugin protected (plugin rt. Status. NO_RESULT); Result.setKeepCallback (true); If (action.equals ("start")) {start (); } And if (action.equals ("goGoogleApp")) {goGoogleApp (args); } And {Return new plugin result (plugin result status.INVALID_ACTION); } Return results; } / ** * The main activation * / Public Zero Start () refers to an intent (reference reference = cordova. Gat activity); intent = new intent (reference, main activity category); //intent.addFlags (Intent.FLAG_ACTIVITY_NO_ANIMATION); (activity) reference) .startActivity;} // public zero goGoogleApp (JSONArray args) {reference reference = cordova.getActivity (); string ADR = ""; log D. ("GMAP ", Adrar; Try {addr = args.getString (0);} Hold (JSOXEction E) {// The Panic (New Plugin Result (Plugin District status .ARRO, this callback); callBackId.error (0);} Uri Uri = Uri.pars ("http://maps.google.co.in/maps?q=" + addr); Intent This = new intent (Intent.ACTION_VIEW, uri); ((activity) reference) .startActivity (this);}}  

config.xml

  & lt; feature name = "menactivity starter">   

Can anyone help, I think I have followed every online guide I am thanks

< P>

Comments