|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface DisplayManager
Interface to manage the display of application screens and alert dialogs. To be implemented on cient side. The calls to this class instance are usually made by the DialogController Class.
Field Summary | |
---|---|
static int |
FIRST_SYNC_DIALOG_ID
first sync alert dialog id |
static long |
NO_LIMIT
int value related to the infinitive time to wait before dismissing a screen or a dialog |
static int |
REFRESH_DIRECTION_DIALOG_ID
Refresh direction alert dialog id |
static int |
REFRESH_TYPE_DIALOG_ID
Refresh type alert dialog id |
Method Summary | |
---|---|
void |
addPostDismissSelectionDialogAction(int id,
java.lang.Runnable dismissAction)
Record the action to be executed after dismissing the alert |
boolean |
askAcceptDenyQuestion(java.lang.String question,
boolean defaultyes,
long timeToWait)
Helper function to prompt the user for an accept/deny answer Helper function to prompt the user for a yes/no answer |
void |
askYesNoQuestion(Screen screen,
java.lang.String question,
java.lang.Runnable yesAction,
java.lang.Runnable noAction,
long timeToWait)
Helper function to prompt the user for a yes/no answer |
void |
dismissProgressDialog(Screen screen,
int id)
Dismisses a progress dialog given its id |
void |
dismissSelectionDialog(int id)
Dismiss a previously shown selection dialog given its id |
void |
hideScreen(Screen screen)
Hide a screen pulling it to the background |
void |
loadBrowser(java.lang.String url)
Load the browser to the given url To be implemented. |
boolean |
promptNext(java.lang.String message)
Prompt a message to continue or cancel some pending process |
void |
promptSelection(Screen screen,
java.lang.String question,
DialogOption[] options,
int defaultValue,
int dialogId)
Prompt a selection of different options to the user |
void |
removePostDismissSelectionDialogAction(int id)
Remove the action to be executed after dismissing a given alert |
void |
showMessage(Screen screen,
java.lang.String message)
Prompt a message to the user |
void |
showMessage(Screen screen,
java.lang.String message,
int delay)
Prompt a message to the user for a given amount of time |
int |
showProgressDialog(Screen screen,
java.lang.String prompt)
Shows a progress dialog with the given text prompt |
void |
showScreen(Screen screen,
int screenId)
Shows a screen putting it in foreground |
void |
showScreen(Screen screen,
int screenId,
boolean donotwait)
Shows a screen putting it in foreground |
void |
toBackground()
Put the application in background (unactive state) |
void |
toForeground()
Put the application in foreground (Active satus) |
Field Detail |
---|
static final int REFRESH_DIRECTION_DIALOG_ID
static final int REFRESH_TYPE_DIALOG_ID
static final int FIRST_SYNC_DIALOG_ID
static final long NO_LIMIT
Method Detail |
---|
void hideScreen(Screen screen) throws java.lang.Exception
screen
- The screen to be hidden
java.lang.Exception
void showScreen(Screen screen, int screenId) throws java.lang.Exception
screen
- the Screen to be shownscreenId
- the screen id related to the Screen to be shown
java.lang.Exception
- if an error occurredvoid showScreen(Screen screen, int screenId, boolean donotwait) throws java.lang.Exception
screen
- the Screen to be shownscreenId
- the screen id related to the Screen to be showndonotwait
- if true the screen must be shown immediately
java.lang.Exception
- if an error occurredvoid askYesNoQuestion(Screen screen, java.lang.String question, java.lang.Runnable yesAction, java.lang.Runnable noAction, long timeToWait)
question
- the question to be displayeddefaultyes
- the default otpiontimeToWait
- time to wait before dismissing the dialog in millisecondsboolean askAcceptDenyQuestion(java.lang.String question, boolean defaultyes, long timeToWait)
question
- the question to be displayeddefaultyes
- the default otpiontimeToWait
- time to wait before dismissing the dialog in milliseconds
int showProgressDialog(Screen screen, java.lang.String prompt)
screen
- the alert dialog owner Screenprompt
- the message to be prompted
void dismissProgressDialog(Screen screen, int id)
screen
- the alert dialog owner Screenid
- the dialog id related to the dialog to be dismissedvoid dismissSelectionDialog(int id)
id
- the int id of the dialog to be dismissedvoid addPostDismissSelectionDialogAction(int id, java.lang.Runnable dismissAction)
id
- the int id of the dialog to be dismisseddismissAction
- the Runnable that represents what to do after the
alert is dismissedvoid removePostDismissSelectionDialogAction(int id)
id
- the int id of the dialog for wich the action is pendingboolean promptNext(java.lang.String message)
message
- the message to be prompted
void showMessage(Screen screen, java.lang.String message)
screen
- the screen where to prompt the messagemessage
- the String formatted message to displayvoid showMessage(Screen screen, java.lang.String message, int delay)
screen
- the screen where to prompt the messagemessage
- the String formatted message to displaydelay
- the message delayvoid promptSelection(Screen screen, java.lang.String question, DialogOption[] options, int defaultValue, int dialogId)
screen
- the alert dialog owner Screenquestion
- the message that describe the selectionoptions
- An array of DialogOption objectsdefaultValue
- The default value for this selectiondialogId
- the dialog id related to the type of scelection dialog
to be promptedvoid toForeground()
void toBackground()
void loadBrowser(java.lang.String url)
url
- the url to be set on the browser
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |