/** * Toggle the SlidingMenu. If it is open, it will be closed, and vice versa. * * @param animate true to animate the transition, false to ignore animation */ public void toggle(boolean animate) { if (isMenuShowing()) { showContent(animate); } else { showMenu(animate); } }
/** Closes the menu and shows the above view. */ public void showContent() { showContent(true); }
@Override public void onResume() { super.onResume(); if (slidingMenu.isMenuShowing()) slidingMenu.showContent(false); }
/** * Set the above view content to the given View. * * @param view The desired content to display. */ public void setContent(View view) { mViewAbove.setContent(view); showContent(); }
/** Close the SlidingMenu and show the content view. */ public void showContent() { mSlidingMenu.showContent(); }