|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.simonvt.widget.MenuDrawerManager
public class MenuDrawerManager
| Constructor Summary | |
|---|---|
MenuDrawerManager(android.app.Activity activity,
int dragMode)
Constructor to use when creating the menu drawer. |
|
MenuDrawerManager(android.app.Activity activity,
int dragMode,
int gravity)
Constructor to use when creating the menu drawer. |
|
| Method Summary | |
|---|---|
void |
closeMenu()
Closes the menu. |
void |
closeMenu(boolean animate)
Closes the menu. |
int |
getDrawerState()
Returns the state of the drawer. |
MenuDrawer |
getMenuDrawer()
Returns the MenuDrawer layout. |
android.view.View |
getMenuView()
Returns the menu view. |
boolean |
isMenuVisible()
Indicates whether the menu is currently visible. |
void |
onRestoreDrawerState(android.os.Parcelable in)
Called to restore the MenuDrawer's state that has previously been generated with onSaveDrawerState(). |
android.os.Parcelable |
onSaveDrawerState()
Returns the views current state. |
void |
openMenu()
Opens the menu. |
void |
openMenu(boolean animate)
Opens the menu. |
void |
setActiveView(android.view.View v)
Set the active view. |
void |
setActiveView(android.view.View v,
int position)
Set the active view. |
void |
setContentView(int layoutResId)
Set the content from a layout resource. |
void |
setContentView(android.view.View view)
Set the content to an explicit view. |
void |
setContentView(android.view.View view,
android.view.ViewGroup.LayoutParams params)
Set the content to an explicit view. |
void |
setMenuView(int layoutResId)
Set the menu view from a layout resource. |
void |
setMenuView(android.view.View view)
Set the menu view to an explicit view. |
void |
setMenuView(android.view.View view,
android.view.ViewGroup.LayoutParams params)
Set the menu view to an explicit view. |
void |
toggleMenu()
Toggles the menu open and close. |
void |
toggleMenu(boolean animate)
Toggles the menu open and close. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public MenuDrawerManager(android.app.Activity activity,
int dragMode)
activity - The activity the menu drawer will be attached to.dragMode - The drag mode of the drawer. Can be either MenuDrawer.MENU_DRAG_CONTENT
or MenuDrawer.MENU_DRAG_WINDOW.
public MenuDrawerManager(android.app.Activity activity,
int dragMode,
int gravity)
activity - The activity the menu drawer will be attached to.dragMode - The drag mode of the drawer. Can be either MenuDrawer.MENU_DRAG_CONTENT
or MenuDrawer.MENU_DRAG_WINDOW.gravity - Where to position the menu. Can be either MenuDrawer.MENU_POSITION_LEFT or
MenuDrawer.MENU_POSITION_RIGHT.| Method Detail |
|---|
public MenuDrawer getMenuDrawer()
public void setActiveView(android.view.View v)
v - The active view.
public void setActiveView(android.view.View v,
int position)
v - The active view.position - Optional position, usually used with ListView. v.setTag(R.id.mdActiveViewPosition, position)
must be called first.public void toggleMenu()
public void toggleMenu(boolean animate)
animate - Whether open/close should be animated.public void openMenu()
public void openMenu(boolean animate)
animate - Whether open/close should be animated.public void closeMenu()
public void closeMenu(boolean animate)
animate - Whether open/close should be animated.public boolean isMenuVisible()
public int getDrawerState()
MenuDrawer.STATE_CLOSED, MenuDrawer.STATE_CLOSING,
MenuDrawer.STATE_DRAGGING, MenuDrawer.STATE_OPENING or MenuDrawer.STATE_OPEN.
public void setMenuView(int layoutResId)
layoutResId - Resource ID to be inflated.public void setMenuView(android.view.View view)
view - The menu view.
public void setMenuView(android.view.View view,
android.view.ViewGroup.LayoutParams params)
view - The menu view.params - Layout parameters for the view.public android.view.View getMenuView()
public void setContentView(int layoutResId)
layoutResId - Resource ID to be inflated.public void setContentView(android.view.View view)
view - The desired content to display.
public void setContentView(android.view.View view,
android.view.ViewGroup.LayoutParams params)
view - The desired content to display.params - Layout parameters for the view.public android.os.Parcelable onSaveDrawerState()
public void onRestoreDrawerState(android.os.Parcelable in)
onSaveDrawerState().
in - The state that had previously been returned by onSaveDrawerState().
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||