Where to put native code for Phonegap 3.0 plugin? - iphone

I just upgraded one of my projects to PhoneGap 3.0 and was wondering the proper methodology for developing a custom plugin. I'm following the Echo plugin example from the developer docs. Should the Echo.h and Echo.m files go in the Plugins folder in the project root, or within the Plugins folder for the specific platform being built?

I tried Echo Plugin for iOS and it's working for me. I put Echo.h and Echo.m under platforms/ios/TestProject/Plugins/. Root folder plugins keep plugins your download from command line. It will be auto installed when you make iOS, Android or other platforms.

Related

build a cordova plugin for android from source code

I'm a .Net developer and I've some basic information about java development , I'm developing a multi-device-hybrid-apps using visual studio and cordova.
I use a native plugin for push notifications PushPlugin , I want to do some changes in this plugin using java , i downloaded eclipse and ADT plugin .
actually my problem is in using eclipse not in understanding java code (what is project template in eclipse should i use to create android library ), I've created a new android project and added the PushPlugin code that I downloaded from GitHub , but "android project" is generating an android app not just a jar file to use as a cordova plugin.
What I want is to make some modifications in the plugin code and re-build it using eclipse to generate a new jar file.
please advice.
ok i found a way to overcome this issue , It's mainly caused by my lack understanding to how cordova plugins works , so i decided to write steps , it may help someone who has few knowledge about java and cordova plugins.
to edit a downloaded (with source-code) plugin from github
you don't need to install eclipse at all.
you need to have some knowledge in java and android API
in visual studio navigate to your plugin source code under plugins folder , in this case it's \plugins\com.phonegap.plugins.PushPlugin\src\android\com\plugin\gcm
find the plugin starting class which will be a class extends CordovaPlugin
edit what you want in java code
now in order to re-build java code , you MUST Clean cordova project before making a new deploy.
That's all.

How to install ADT 11.0.0 on Eclipse(helios)

I am a Fresh developer of Android application,
can anyone please help that how i can install ADT 11.0.0 on Eclipse(Helios),
i tried my best at least two days to overcome on this issue,but this error is coming continually that conflicting dependency is present.
First Method:
I tried to put ADT 11.0.0 offline in eclipse but this is not affecting,means i just copy paste plugin and features folder of ADT 11.0.0 in eclipse(helios)..
SECOND METHOD:
I used this URL http://dl-ssl.google.com/android/eclipse/ to install ADT 11.0.0 online,
Here is screen shots,
![This is an error which i am facing through online installation.]
I shall be very thankful if anyone helps me..........
Thanking you,
HelperANDFinder.
#HelperAndFinder, you can directly download Eclipse ADT bundle, advantage is that:
With a single download, the Eclipse ADT bundle includes everything you need to begin developing apps:
Eclipse + ADT plugin
Android SDK Tools
Android Platform-tools
A version of the Android platform
A version of the Android system image for the emulator
Means you don't need to install ADT separately, just you need to download this bundle and your job done.
http://developer.android.com/sdk/index.html
That is one way, other way is:
Update an Eclipse IDE for Android development, in which you are more
interested. Kindly look into this link to see step by step procedure:
Click here - This link provides step by step guidance on same.
And for exploring Android in detail with to the point then check out this link:
And to give you high level overview then
Eclipse is IDE which supports Android App Development through plugin or as Complete package which is the first way.
Androi SDK - A Software Development Kit that enables developers to create applications for the Android platform. The Android SDK includes sample projects with source code, development tools, an emulator, and required libraries to build Android applications. Applications are written using the Java programming language and run on Dalvik, a custom virtual machine designed for embedded use which runs on top of a Linuxkernel.
ADT - ADT (Android Developer Tools) is a plugin for Eclipse that helps you to develop Android applications quickly. ADT provides GUI access to many of the command line SDK tools as well as a UI design tool for rapid prototyping, designing, and building of your application's user interface means just drag and drop thing is there to come up with basic layout for your application like we did in swing, and AWT kind of application. It's more than that just explore it more...;)

Cordova Social Sharing Plugin not working in NetBeans 8 Cordova Build

I installed Social Sharing Plugin using Command Prompt in my cordova 3.3 project of NetBeans 8
https://github.com/EddyVerbruggen/SocialSharing-PhoneGap-Plugin
After successful plugin installation. The social sharing plugin is listed in the plugins folder. But when is try to build and run the app. Netbeans builder automatically removes the installed social sharing plugin. Check the log below
check-android-template:
check-cordova-version:
check-cordova-project:
upgrade-to-cordova-project:
create-android:
update-plugins:
cordova.cmd plugins
cordova.cmd -d plugin remove nl.x-services.plugins.socialsharing
Calling plugman.uninstall on plugin "nl.x-services.plugins.socialsharing" for platform "android"
Uninstalling nl.x-services.plugins.socialsharing from android
Beginning processing of action stack for android project...
NetBeans' build process parses list of plugins declared via Project properties (for so-called "core" plugins known by NetBeans) or from plugin.properties file (actually in project properties NetBeans reads this file and display/adds core plugins from/to it). Have a look at this screenshot, it says that you can add custom plugins by modifying nbproject/plugins.properties file. If you add the Social sharing plugin to this file, you should be OK.

Error setting up project with latest version of jQuery Mobile and MDS AppLaud for Eclipse

I am starting with PhoneGap development. I had set up Eclipse-ADT bundle and MDS AppLaud plugin. When creating a new PhoneGap project, I can chose built-in versions of PhoneGap (1.4.1 to 1.9) and jQuery Mobile 1.1. There's an option to use already installed versions for each one. No problem whith PhoneGap 3.4, but with jQuery, I have this error:
All .js and .css files in the jQuery Mobile directory
/foo/bar/jquery.mobile-1.4.2 must have the same version number of the
form jquery.mobile-{version}.*
I removed Demos directory and min versions of css and js, but I still get the same error, maybe because there are some more css files with the form jquery.mobile.something-1.4.2.css
How can I solve this error using latest jQuery Mobile?
Thanks
I had the same problem, but when I delete everything without /images/ folder and these: jquery.mobile-1.4.5.css, jquery.mobile-1.4.5.min.css, jquery.mobile-1.4.5.js, jquery.mobile-1.4.5.min.js and everything works great with Eclipse. :)

Cant re-install Google Web Toolkit using Eclipse plugin

I installed and updated Google Plugin for Eclipse 3.7 a few weeks ago. It installed GWT as well as other things. I was able to compile a Google App. I did several things on Eclipse today and now GWT is gone. I look at Preference-->Google-->Web Toolkit; the list is empty. I ran plugin update, it keep saying GWT is already installed and refuse to update/re-install. I uninstall GWT explicitly and run plugin update; it update without complaint. But the Preference-->Google-->Web Toolkit; the list is still empty!
How do I force plugin to populate the SDK info in Preference-->Google-->Web Toolkit?
There is actually an "Add" button to configure SDK. But I dont know the installation directory of GWT. Where does Eclipse plugin save the GWT?
Seems Eclipse keep track of the installation of GWT SDK in two different place?
My GWT SDK database seems corrupted, and Eclipse plugin seems rely on its own private data base of the status of installation of GWT SDK?
Can anyone please help?
I think that what you are referring is not the plugin but the SDK.
Download the SDK unzip it then add it preferences->Google->Web Toolkit.
The link to to download the SDK is: http://code.google.com/p/google-web-toolkit/