×

Discussion Board

Results 1 to 3 of 3
  1. #1
    Registered User
    Join Date
    Nov 2008
    Posts
    13

    Nokia 5220 XpressMusic - 3 commands, 3 buttons

    Hello all,
    I'm currently developing a j2me application and i have the following problem:
    I have a MyList class that extends the List class. I need to use 3 commands with this list. One is "Forward", then "Backward" an the last one is "Cancel". Here is a piece of code:
    Code:
    backCommand = new Command("Cancel", Command.BACK, 1);
    forwardCommand = List.SELECT_COMMAND;
    backwardCommand = new Command("Back", Command.ITEM, 2);
    addCommand(forwardCommand);
    addCommand(backwardCommand);
    addCommand(backCommand);
    setCommandListener(this);
    Unfortunately on my mobile only "Cancel" and "Back" commands are displayed despite the fact that my device has 3 control buttons. How to force the phone to display all three commands and (optional) to force it to display the commands in a specific order? All ideas are welcome, thank You

  2. #2
    Super Contributor
    Join Date
    Mar 2008
    Location
    The Capital of INDIA
    Posts
    4,328

    Thumbs up Re: Nokia 5220 XpressMusic - 3 commands, 3 buttons

    Quote Originally Posted by Opalo View Post
    Hello all,

    Unfortunately on my mobile only "Cancel" and "Back" commands are displayed despite the fact that my device has 3 control buttons. How to force the phone to display all three commands and (optional) to force it to display the commands in a specific order? All ideas are welcome, thank You
    Please check that what java doces says,
    The application uses the priority value to describe the importance of this command relative to other commands on the same screen. Priority values are integers, where a lower number indicates greater importance. The actual values are chosen by the application. A priority value of one might indicate the most important command, priority values of two, three, four, and so on indicate commands of lesser importance.

    Typically, the implementation first chooses the placement of a command based on the type of command and then places similar commands based on a priority order. This could mean that the command with the highest priority is placed so that user can trigger it directly and that commands with lower priority are placed on a menu. It is not an error for there to be commands on the same screen with the same priorities and types. If this occurs, the implementation will choose the order in which they are presented.

    For example, if the application has the following set of commands:


    new Command("Buy", Command.ITEM, 1);
    new Command("Info", Command.ITEM, 1);
    new Command("Back", Command.BACK, 1);

    An implementation with two soft buttons may map the BACK command to the right soft button and create an "Options" menu on the left soft button to contain the other commands.

    When user presses the left soft button, a menu with the two remaining Commands appears:

    If the application had three soft buttons, all commands can be mapped to soft buttons:

    "The application is always responsible for providing the means for the user to progress through different screens. An application may set up a screen that has no commands. This is allowed by the API but is generally not useful; if this occurs the user would have no means to move to another screen. Such program would simply considered to be in error. A typical device should provide a means for the user to direct the application manager to kill the erroneous application."

    Thanks,
    Thanks with Regards,

    R a j - The K e r n e l


    Join Delhi-NCR Nokia Developer's Community,

  3. #3
    Registered User
    Join Date
    Nov 2008
    Posts
    13

    Re: Nokia 5220 XpressMusic - 3 commands, 3 buttons

    Thank You very much raj_J2ME
    Please check that what java doces says
    You are absolutely right, that's my oversight.

Similar Threads

  1. Infra-red capability
    By Symbian_Challenge_0412 in forum General Development Questions
    Replies: 1
    Last Post: 2005-08-16, 18:24
  2. Nokia 7650 support Bluetooth audo?
    By ovjo12 in forum Bluetooth Technology
    Replies: 5
    Last Post: 2003-07-17, 18:50

Posting Permissions

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