Back to project page SlidingMenuLibrary.
The source code is released under:
Apache License
If you think the Android project SlidingMenuLibrary listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package com.jeremyfeinstein.slidingmenu.example; /* ww w . j a v a 2s . c om*/ import android.os.Bundle; import android.view.KeyEvent; import android.view.View; import android.view.ViewGroup; import com.jeremyfeinstein.slidingmenu.example.fragments.ColorFragment; import com.jeremyfeinstein.slidingmenu.lib.SlidingMenu; import com.jeremyfeinstein.slidingmenu.lib.SlidingMenu.OnClosedListener; import com.jeremyfeinstein.slidingmenu.lib.SlidingMenu.OnOpenedListener; public class LeftAndRightActivity extends BaseActivity { public LeftAndRightActivity() { super(R.string.left_and_right); } @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); getSlidingMenu().setMode(SlidingMenu.LEFT_RIGHT); getSlidingMenu().setTouchModeAbove(SlidingMenu.TOUCHMODE_FULLSCREEN); setContentView(R.layout.content_frame); getSupportFragmentManager() .beginTransaction() .replace(R.id.content_frame, new SampleListFragment()) .commit(); getSlidingMenu().setSecondaryMenu(R.layout.menu_frame_two); getSlidingMenu().setSecondaryShadowDrawable(R.drawable.shadowright); getSupportFragmentManager() .beginTransaction() .replace(R.id.menu_frame_two, new SampleListFragment()) .commit(); } }