Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Porting app from LWUIT to CodenameOne

I have 3 apps developed in LWUIT using the Resource editor and adding more functionallity with Netbeans. I want to port them to codenameone. What is the best way to do that?
I see that the navite Componentsfrom LWUIT have an equivalent Componentin codenameone, but J2ME methods and classes , now have to be ported to J2SE, is that right?
The methods in the StateMachineBase have changed too. showForm() for example, doesn't exist now.What further changes are in StateMachineBase?

Thanks

like image 706
Mun0n Avatar asked Oct 09 '22 06:10

Mun0n


1 Answers

Start by creating a new Codename One project then just copy your source code/resource files and fix the import statements.

You can't use the MIDP API's anymore (and you can't use J2SE either), there are new API's and a new lifecycle object which you can use for pretty much everything. showForm does exist and wasn't modified, I'm not exactly sure why you didn't find it.

Generally Codename One is much simpler since it doesn't have the project hierarchy issue and you don't need to deal with MIDP/RIM/Android differences. Its all handled for you.

like image 182
Shai Almog Avatar answered Oct 12 '22 10:10

Shai Almog