Java SDK for 2D
 All Classes Namespaces Functions Variables Pages
ApiMenu Class Reference

ApplicationMenu class defines menu items which can be accessed by ApiMenu#onMenuCommand(int, int, int) method. More...

Classes

class  ID
 ApplicationMenu.ID enum contains list of accessible menus by ApiMenu#onMenuCommand(int, int, int) method. More...
 
class  IdMenuBrowseMap
 IdBrowseMap enum contains list of actions (buttons) in Map options menu accessible by ApiMenu#onMenuCommand(int, int, int) method. More...
 
class  IdMenuContext
 Context menu. More...
 
class  IdMenuDemonstrate
 IdMenuDemonstrate enum contains list of actions (buttons) in Route demonstration menu accessible by ApiMenu#onMenuCommand(int, int, int) method. More...
 
class  IdMenuExtras
 Extras menu. More...
 
class  IdMenuMain
 IdMenuMain enum contains list of actions (buttons) in Main menu accessible by ApiMenu#onMenuCommand(int, int, int) method. More...
 
class  IdMenuMainAlternative
 IdMenuMainAlternative enum contains list of actions (buttons) in Alternative route menu accessible by ApiMenu#onMenuCommand(int, int, int) method. More...
 
class  IdMenuManagePoi
 IdMenuManagePoi enum contains list of actions (buttons) in Manage POI menu accessible by ApiMenu#onMenuCommand(int, int, int) method. More...
 
class  IdMenuNavigateTo
 IdMenuNavigateTo enum contains list of actions (buttons) in Navigate to menu accessible by ApiMenu#onMenuCommand(int, int, int) method. More...
 
class  IdMenuSettings
 IdMenuSettings enum contains list of actions (buttons) in Settings menu accessible by ApiMenu#onMenuCommand(int, int, int) method. More...
 
class  IdMenuSettingsGps
 IdMenuSettingsGps enum contains list of actions (buttons) in Hardware settings menu accessible by ApiMenu#onMenuCommand(int, int, int) method. More...
 
class  IdMenuTraffic
 Not implemented yet. More...
 
class  IdMenuViewRoute
 IdMenuViewRoute enum contains list of actions (buttons) in View route menu accessible by ApiMenu#onMenuCommand(int, int, int) method. More...
 

Static Public Member Functions

static void onMenuCommand (int menuId, int subMenuId, int maxTime) throws GeneralException
 Provides direct access to menu items. More...
 

Detailed Description

ApplicationMenu class defines menu items which can be accessed by ApiMenu#onMenuCommand(int, int, int) method.

Member Function Documentation

static void onMenuCommand ( int  menuId,
int  subMenuId,
int  maxTime 
) throws GeneralException
static

Provides direct access to menu items.

Parameters
menuIdMenu ID to which function provides access. Possible values are enumerated in ApiMenu.ID class
Name of most of ApiMenu.ID items is similar to name of menu displayed in screen top left corner. It is also similar to button name in main menu which opens corresponding menu.
subMenuIdMenu SubID corresponding to menu ID.
Name of most of SubID items is similar to name of correspondig button in corresponding menu (nID).
OnMenuCommand function calls function which is called after clicking this button.
Links to possible enums are listed in ApiMenu.ID.
For example: if nID=ApplicationMenu.ID.IdMenuManagePoi, nSubID must be chosen from ApiMenu.IdMenuManagePoi enum.
maxTimeMaximum of time (in milliseconds) function can take. If maxTime=0 function execution is not time limited. Notes:

Example:

int nID = ApiMenu.ID.IdMenuMain;
int nSubID = ApiMenu.IdMenuMain.OnMainNavigateTo;
int maxTime = 10000;
ApiMenu.onMenuCommand(nID, nSubID, nmaxTime);
       This code shows NavigateTo menu.
Exceptions
GeneralExceptionthe general exception

References Api.getInstance(), and Api.getService().