×

Discussion Board

Results 1 to 8 of 8
  1. #1
    Regular Contributor
    Join Date
    Dec 2012
    Location
    India
    Posts
    271

    Opinion : How do you go about developing LWUIT Apps?

    Hi all,

    I just wanna know how do you go about developing LWUIT applications.Here is how I am doing it so far.

    Consider one application (which doesn't use any Nokia specific API).I generally do the following.

    1.) Develop the app using LWUIT 1.5.
    2.) Use LWUIT for S40 and modify the above variant to create a full touch version of the same app. (Coz the native VKB is faster and better& the app doesn't take up full screen by default. )
    3.) Use LWUIT for Asha platform and create a variant for Asha 501 (& later devices) . ( Coz UI guidelines insists on removing all references to back,exit and few other stuffs).

    I have noticed that there is a LWUIT for Non-Touch Devices and LWUIT for Touch and Type Devices as well.Although I could create a separate variant using these two LWUIT versions, but so far itself, is a pretty time consuming process.I dunno if I am just wasting my time trying to optimize a lot for each device when there might be an easier way to do things.

    Is there a better way to do it ? Is there a way to use Lwuit 1.5 itself and target all types of devices such that

    1.) It uses native keyboard whenever possible instead of the default LWUIT VKB.
    2.) Adapt itself nicely to Asha 501 by default.

    Thanks in advance.

  2. #2
    Registered User
    Join Date
    May 2009
    Location
    Guatemala
    Posts
    186

    Re: Opinion : How do you go about developing LWUIT Apps?

    May I ask why you start developing the app using LWUIT 1.5? I start with the S40 implementation from the beginning.
    -CarlosDL

  3. #3
    Regular Contributor
    Join Date
    Dec 2012
    Location
    India
    Posts
    271

    Re: Opinion : How do you go about developing LWUIT Apps?

    I wish to reach out to as many devices as possible.LWUIT for S40 works only for a selected set of S40 models and is not tested for very old versions of S40.However, LWUIT 1.5 can be used for a large number of devices, even for devices which are not made by Nokia. I just want to maximize my reach of my application.
    Last edited by arunkam; 2013-08-27 at 11:06.

  4. #4
    Regular Contributor
    Join Date
    Dec 2012
    Location
    India
    Posts
    271

    Re: Opinion : How do you go about developing LWUIT Apps?

    I managed to cut down my development time by using preprocessor directives!
    It is extremely handy and now all my code are easy to track and maintain.I am able to build for multiple devices quite easily.

  5. #5
    Registered User
    Join Date
    May 2009
    Location
    Guatemala
    Posts
    186

    Re: Opinion : How do you go about developing LWUIT Apps?

    Quote Originally Posted by arunkam View Post
    I managed to cut down my development time by using preprocessor directives!
    It is extremely handy and now all my code are easy to track and maintain.I am able to build for multiple devices quite easily.
    Good to know.

    Any chances you could share how you are doing it now?
    -CarlosDL

  6. #6
    Nokia Developer Moderator
    Join Date
    Feb 2006
    Location
    Oslo, Norway
    Posts
    28,688

    Re: Opinion : How do you go about developing LWUIT Apps?

    Java has no preprocessor in itself.
    However
    a) you can certainly use external preprocessors, chances are that a C preprocessor does not interfere with Java code (however interference with Java IDE-s may be a different thing), and there are Java-specific ones as well (like https://code.google.com/p/java-comment-preprocessor/ - this one works with "commented preprocessor directives", so IDE-s will not worry about it)
    b) if all parts of your code would compile in general, you can go for conditional compilation with if-s referring to constant expressions, including static final things you can collect into a single place. This intentionally does not trigger "unreachable code" errors, and compilers may entirely leave out the given code parts from the compiled .class file.

  7. #7
    Regular Contributor
    Join Date
    Dec 2012
    Location
    India
    Posts
    271

    Re: Opinion : How do you go about developing LWUIT Apps?

    Quote Originally Posted by wizard_hu_ View Post
    Java has no preprocessor in itself.
    However
    a) you can certainly use external preprocessors, chances are that a C preprocessor does not interfere with Java code (however interference with Java IDE-s may be a different thing), and there are Java-specific ones as well (like https://code.google.com/p/java-comment-preprocessor/ - this one works with "commented preprocessor directives", so IDE-s will not worry about it)
    b) if all parts of your code would compile in general, you can go for conditional compilation with if-s referring to constant expressions, including static final things you can collect into a single place. This intentionally does not trigger "unreachable code" errors, and compilers may entirely leave out the given code parts from the compiled .class file.
    Hi

    Thanks for the explanation.Then I guess I have used the preprocessor directive available in Netbeans IDE itself.

    Here is what I did

    1.) I created 3 configurations, one for Full Touch, one for 501, one for Non-Touch Devices.
    2.) In each configuration, I made the LWUIT library as the one which best fits for each device.I also added/removed resource elements as need be.
    3.) In the code, I used preprocessor directive like

    Code:
    //#ifdef
    ..
    //#else
    ..
    //#endif
    This was mainly used to optimize my code for Touch Screen, Use category bar in FT and 501 whereas simple Commands in NT devices , etc..

  8. #8
    Registered User
    Join Date
    May 2009
    Location
    Guatemala
    Posts
    186

    Re: Opinion : How do you go about developing LWUIT Apps?

    Thanks for sharing !
    -CarlosDL

Similar Threads

  1. Developing symbian apps using qt
    By raj8nokiaforum in forum Symbian
    Replies: 3
    Last Post: 2013-05-07, 10:19
  2. Developing S60 3rd apps in C#
    By ForMiSoft in forum General Development Questions
    Replies: 10
    Last Post: 2010-01-19, 13:36
  3. developing apps on mac
    By kartikbansal in forum Mobile Java General
    Replies: 2
    Last Post: 2008-11-21, 12:54
  4. developing SIP apps with series 60
    By nitin_123 in forum Symbian
    Replies: 2
    Last Post: 2004-08-16, 19:44
  5. Developing apps for Phones
    By arzoo400 in forum Mobile Java General
    Replies: 1
    Last Post: 2002-07-12, 08:37

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
×