8

I am really confused by lot of links: mgwt, Phonegap, Cordova, gwt-phonegap, etc... Can somebody really help me with a few basic questions about all these?

  1. Phonegap and Cordova are one and the same - They will help us to build a mobile deployable component using generated JS files. Am I correct?

  2. Steps provided in the Cordova site to create an Android project and deploy needs generated html, JS and CSS content of our project. So we need to build these before we come here from our project. Right?

  3. Now if I have a simple GWT project, can I build GWT client and deploy the generated web app content (.nocache.js and module html files) directly using step b (Cordova approach) without any changes. I understand that this itself is called a Phonegap project, which we do using Phonegap's Android tutorial

  4. Now if I have used mGWT widgets in my GWT application, what is needed extra before I start using Cordova steps - mGWT compiled code can't be used directly in Cordova Phonegap project?

What is gwt-Phonegap? Why do we need this now? Can somebody really explain what exactly is happening using gwt-Phonegap in some simple words.

Daniel Kurka
  • 7,973
  • 2
  • 24
  • 43
Santosh
  • 1,849
  • 4
  • 19
  • 31

1 Answers1

11

Here are the answers:

  1. Cordova is the open source code base, Phonegap is one distribution of it, like ubuntu is one distribution of the linux kernel.
  2. If you want to deploy a GWT to an android device you need to compile your GWT app and place the output of the compiler in the www folder of the phonegap project.
  3. see 2.
  4. you just build your GWT as normal using mgwt widgets and the phonegap api (gwt-phonegap), compile it with the GWT compiler and copy it to the device.

Here is a video explaining the basic concept around GWT, Phonegap, mgwt & gwt-phonegap: http://www.youtube.com/watch?v=0V0CdhMFiao&feature=plcp

Daniel Kurka
  • 7,973
  • 2
  • 24
  • 43
  • Thanks Daniel. Video was very helpful. GWT-Phonegap comes between GWT HTM5 apps and native Phonegap api interaction. But still practical significance of gwt-phonegap is not clear. As of now, we have used mGWT and GWT widgets in our project. GWT-Phonegap was never used. Without using gwt-phonegap, can we directly compile project and try on cordova(Phonegap) for deployment? What is that adding GWT-Phonegap will change something practically? Can you please explain? – Santosh May 26 '12 at 15:59
  • 3
    gwt-phonegap is there for calling the phonegap api. If you do not need to access the hardware (like Camera, AddressBook) you do not need gwt-phonegap. You are fine with mgwt and your gwt app – Daniel Kurka May 26 '12 at 16:05
  • Thank you very much Daniel :) Now I am very much clear on what I need to do. – Santosh May 26 '12 at 18:14
  • 1
    Just wanted to know one more thing. I have my GWT Platform Web application. Now, I am converting it into a mobile client by replacing GWT widgets with mGWT widgets so that I can reuse most of the code. I was able to see my first Login screen on emulator. I just wanted to confirm that this approach should be absolutely fine? Also, we have used gwt-Validation api extensively in our GWT web application. Now we cannot use them with mGWT widgets. Do we have to build custom gwt-Validation classes for mGWT or we have any other best approaches for UI validations in mGWT? – Santosh May 28 '12 at 16:56
  • was not able to find how to accept answer and hence delayed...sorry – Santosh Jun 01 '12 at 07:35