|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.xtremelabs.robolectric.shadows.ShadowDialog
com.xtremelabs.robolectric.shadows.ShadowAlertDialog
@Implements(value=android.app.AlertDialog.class) public class ShadowAlertDialog
Nested Class Summary | |
---|---|
static class |
ShadowAlertDialog.ShadowBuilder
Shadows the android.app.AlertDialog.Builder class. |
Constructor Summary | |
---|---|
ShadowAlertDialog()
|
Method Summary | |
---|---|
void |
clickOnItem(int index)
Simulates a click on the Dialog item indicated by index . |
android.view.View |
findViewById(int viewId)
|
android.widget.Button |
getButton(int whichButton)
|
boolean[] |
getCheckedItems()
Non-Android accessor. |
java.lang.CharSequence[] |
getItems()
Non-Android accessor. |
static ShadowAlertDialog |
getLatestAlertDialog()
Non-Android accessor. |
java.lang.String |
getMessage()
Non-Android accessor. |
java.lang.String |
getTitle()
Non-Android accessor. |
static void |
reset()
Resets the tracking of the most recently created AlertDialog |
Methods inherited from class com.xtremelabs.robolectric.shadows.ShadowDialog |
---|
__constructor__, __constructor__, cancel, clickOn, dismiss, getContext, getLatestDialog, getLayoutId, getOwnerActivity, getThemeId, getWindow, hasBeenDismissed, hide, isShowing, setContentView, setOnCancelListener, setOnDismissListener, setOwnerActivity, setTitle, setTitle, show |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ShadowAlertDialog()
Method Detail |
---|
public static ShadowAlertDialog getLatestAlertDialog()
AlertDialog
, or null if none has been created during this test run@Implementation public android.view.View findViewById(int viewId)
findViewById
in class ShadowDialog
public static void reset()
AlertDialog
public void clickOnItem(int index)
Dialog
item indicated by index
. Handles both multi- and single-choice
dialogs, tracks which items are currently checked and calls listeners appropriately.
index
- the index of the item to click on@Implementation public android.widget.Button getButton(int whichButton)
public java.lang.CharSequence[] getItems()
public java.lang.String getTitle()
getTitle
in class ShadowDialog
public java.lang.String getMessage()
public boolean[] getCheckedItems()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |