当前位置: 首页>>代码示例>>Java>>正文


Java SlidingMenu.setShadowDrawable方法代码示例

本文整理汇总了Java中com.jeremyfeinstein.slidingmenu.lib.SlidingMenu.setShadowDrawable方法的典型用法代码示例。如果您正苦于以下问题:Java SlidingMenu.setShadowDrawable方法的具体用法?Java SlidingMenu.setShadowDrawable怎么用?Java SlidingMenu.setShadowDrawable使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在com.jeremyfeinstein.slidingmenu.lib.SlidingMenu的用法示例。


在下文中一共展示了SlidingMenu.setShadowDrawable方法的14个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: createUsersSlidingMenu

import com.jeremyfeinstein.slidingmenu.lib.SlidingMenu; //导入方法依赖的package包/类
/**
 * Setup current users {@link SlidingMenu}
 */

private void createUsersSlidingMenu()
{
    // configure the SlidingMenu
    mCurrentUsers_SlidingMenu = new SlidingMenu(MainActivity.this);
    mCurrentUsers_SlidingMenu.setMode(SlidingMenu.RIGHT);
    //mCurrentUsers_SlidingMenu.setTouchModeAbove(SlidingMenu.TOUCHMODE_MARGIN);
    mCurrentUsers_SlidingMenu.setShadowWidthRes(R.dimen.shadow_width);
    mCurrentUsers_SlidingMenu.setShadowDrawable(new ColorDrawable(getResources().getColor(R.color.transparentGrey)));
    mCurrentUsers_SlidingMenu.setBehindWidthRes(R.dimen.sliding_menu_width);
    mCurrentUsers_SlidingMenu.setFadeDegree(0.35f);
    mCurrentUsers_SlidingMenu.attachToActivity(MainActivity.this, SlidingMenu.SLIDING_CONTENT);
    mCurrentUsers_SlidingMenu.setMenu(R.layout.users_slideout);
    mCurrentUsers_SlidingMenu.setTouchModeAbove(SlidingMenu.TOUCHMODE_NONE);
    mCurrentUsers_SlidingMenu.setOnOpenedListener(new SlidingMenu.OnOpenedListener()
    {
        @Override
        public void onOpened()
        {
            TutorialStuff.showUsersTutorial(MainActivity.this);
        }
    });
}
 
开发者ID:HueToYou,项目名称:ChatExchange-old,代码行数:27,代码来源:MainActivity.java

示例2: initSlideMenu

import com.jeremyfeinstein.slidingmenu.lib.SlidingMenu; //导入方法依赖的package包/类
private void initSlideMenu() {
        setBehindContentView(R.layout.menu_home);
        //获取到slidingMenu对象
        SlidingMenu slidingMenu = getSlidingMenu();
        slidingMenu.setMode(SlidingMenu.RIGHT);
        slidingMenu.setShadowWidthRes(R.dimen.shadow_width);
        slidingMenu.setShadowDrawable(R.drawable.shadow);

        //设置为全屏拉出菜单
        slidingMenu.setTouchModeAbove(SlidingMenu.TOUCHMODE_FULLSCREEN);
        //设置菜单拉出后剩余屏幕宽度
//让侧拉菜单充满屏幕的四分之三
        int menuWidth=getWitdh();
        slidingMenu.setBehindOffset(menuWidth);
        slidingMenu.setOnCloseListener(new SlidingMenu.OnCloseListener() {
            @Override
            public void onClose() {
                Log.d("changecity", "菜单关闭");
                mFragWether.refreshData();
                mFragSlideMenu.stopAlarmMusic();
            }
        });
    }
 
开发者ID:JoeSteven,项目名称:Moring-Alarm,代码行数:24,代码来源:HomeActivity.java

示例3: initMenu

import com.jeremyfeinstein.slidingmenu.lib.SlidingMenu; //导入方法依赖的package包/类
private void initMenu() {
	SlidingMenu menu = getSlidingMenu();
	//����ͨ������
	menu.setMode(SlidingMenu.LEFT_RIGHT);
	menu.setTouchModeAbove(SlidingMenu.TOUCHMODE_MARGIN);
	menu.setShadowWidthRes(R.dimen.shadow_width);
	menu.setShadowDrawable(R.drawable.shadow);
	menu.setBehindOffsetRes(R.dimen.slidingmenu_offset);
	menu.setFadeDegree(0.35f);

	//���IJ˵�
	setBehindContentView(R.layout.menu_left);//���Ҳ಻��ʹ��ͬһ�����֣�����replace���Ŀؼ���ID������ͬ����֪��Ϊʲô�������������
	Fragment leftMenuFragment = new MainTabFragment2("���˵�");
	getSupportFragmentManager().beginTransaction().replace(R.id.menu_left, leftMenuFragment).commit();

	//�Ҳ�˵�����
	menu.setSecondaryShadowDrawable(R.drawable.shadow);//������Դ�ļ�ID�������ұߣ������������˵�����ӰЧ��
	menu.setSecondaryMenu(R.layout.menu_right);//�����ұ߲໬�˵�
	Fragment rightMenuFragment = new MainTabFragment2("�Ҳ�˵�");
	getSupportFragmentManager().beginTransaction().replace(R.id.menu_right, rightMenuFragment).commit();
}
 
开发者ID:baiqiantao,项目名称:MainUI,代码行数:22,代码来源:MainActivity3.java

示例4: onCreate

import com.jeremyfeinstein.slidingmenu.lib.SlidingMenu; //导入方法依赖的package包/类
@Override
protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.activity_main);
    // configure the SlidingMenu
    SlidingMenu menu = new SlidingMenu(this);
    menu.setMode(SlidingMenu.LEFT);
    // 设置触摸屏幕的模式
    menu.setTouchModeAbove(SlidingMenu.TOUCHMODE_MARGIN);
    menu.setShadowWidthRes(R.dimen.shadow_width);
    menu.setShadowDrawable(R.color.colorPrimary);

    // 设置滑动菜单视图的宽度
    menu.setBehindOffsetRes(R.dimen.slidingmenu_offset);
    // 设置渐入渐出效果的值
    menu.setFadeDegree(0.35f);
    /**
     * SLIDING_WINDOW will include the Title/ActionBar in the content
     * section of the SlidingMenu, while SLIDING_CONTENT does not.
     */
    menu.attachToActivity(this, SlidingMenu.SLIDING_CONTENT);
    //为侧滑菜单设置布局
    menu.setMenu(R.layout.layout_left_menu);
}
 
开发者ID:hongyang51,项目名称:SlidingMenu4Studio,代码行数:25,代码来源:MainActivity.java

示例5: initSlidingMenu

import com.jeremyfeinstein.slidingmenu.lib.SlidingMenu; //导入方法依赖的package包/类
private void initSlidingMenu(Bundle savedInstanceState) {
    // check if the content frame contains the menu frame
    if (findViewById(R.id.menu_frame) == null) {
        setBehindContentView(R.layout.menu_frame);
        getSlidingMenu().setSlidingEnabled(true);
        getSlidingMenu()
                .setTouchModeAbove(SlidingMenu.TOUCHMODE_FULLSCREEN);
    } else {
        // add a dummy view
        View v = new View(this);
        setBehindContentView(v);
        getSlidingMenu().setSlidingEnabled(false);
        getSlidingMenu().setTouchModeAbove(SlidingMenu.TOUCHMODE_NONE);
    }

    // 设置主界面Fragment视图内容
    if (savedInstanceState != null)
        mContent = getSupportFragmentManager().getFragment(
                savedInstanceState, "mContent");
    if (mContent == null)
        mContent = new GlanceMainFragment();

    getSupportFragmentManager().beginTransaction()
            .replace(R.id.content_frame, mContent).commit();

    // set the Behind View Fragment
    getSupportFragmentManager().beginTransaction()
            .replace(R.id.menu_frame, new MainMenuFragment()).commit();

    // 设置滑动菜单的属性值
    SlidingMenu sm = getSlidingMenu();
    sm.setBehindOffsetRes(R.dimen.slidingmenu_offset);
    sm.setShadowWidthRes(R.dimen.shadow_width);
    sm.setShadowDrawable(R.drawable.shadow);
    sm.setBehindScrollScale(0.25f);
    sm.setFadeDegree(0.25f);
}
 
开发者ID:Datatellit,项目名称:xlight_android_native,代码行数:38,代码来源:SlidingMenuMainActivity.java

示例6: onCreate

import com.jeremyfeinstein.slidingmenu.lib.SlidingMenu; //导入方法依赖的package包/类
@Override
public void onCreate(Bundle savedInstanceState) {
	super.onCreate(savedInstanceState);

	setTitle(R.string.attach);

	// set the Above View
	setContentView(R.layout.content_frame);
	getSupportFragmentManager()
	.beginTransaction()
	.replace(R.id.content_frame, new SampleListFragment())
	.commit();

	// configure the SlidingMenu
	menu = new SlidingMenu(this);
	menu.setTouchModeAbove(SlidingMenu.TOUCHMODE_FULLSCREEN);
	menu.setShadowWidthRes(R.dimen.shadow_width);
	menu.setShadowDrawable(R.drawable.shadow);
	menu.setBehindOffsetRes(R.dimen.slidingmenu_offset);
	menu.setFadeDegree(0.35f);
	menu.attachToActivity(this, SlidingMenu.SLIDING_CONTENT);
	menu.setMenu(R.layout.menu_frame);
	getSupportFragmentManager()
	.beginTransaction()
	.replace(R.id.menu_frame, new SampleListFragment())
	.commit();
}
 
开发者ID:JoeSteven,项目名称:Moring-Alarm,代码行数:28,代码来源:AttachExample.java

示例7: initSlideMenu

import com.jeremyfeinstein.slidingmenu.lib.SlidingMenu; //导入方法依赖的package包/类
private void initSlideMenu() {
	setBehindContentView(createFrameLayout(FRAGMENT_LEFT_MANU_ID));
	SlidingMenu mSlidingMenu = getSlidingMenu();
	mSlidingMenu.setMode(SlidingMenu.LEFT);
	mSlidingMenu.setShadowWidthRes(R.dimen.shadow_width);
	mSlidingMenu.setShadowDrawable(null);
	mSlidingMenu.setBehindOffsetRes(R.dimen.slidingmenu_offset);
	mSlidingMenu.setFadeDegree(0.35f);
	mSlidingMenu.setTouchModeAbove(SlidingMenu.TOUCHMODE_MARGIN);
	mSlidingMenu.setBehindScrollScale(0.0f);
}
 
开发者ID:wangcantian,项目名称:Mobile-Office,代码行数:12,代码来源:MainActivity.java

示例8: onCreate

import com.jeremyfeinstein.slidingmenu.lib.SlidingMenu; //导入方法依赖的package包/类
@Override
public void onCreate(Bundle savedInstanceState) {
	super.onCreate(savedInstanceState);
	bus.register(this);
	ActionBar actionBar = getActionBar();
	actionBar.setCustomView(R.layout.custom_actionbar);
	listName = (TextView) actionBar.getCustomView().findViewById(R.id.viewListNameActionBar);
	actionBar.setDisplayShowCustomEnabled(true);
	actionBar.setDisplayHomeAsUpEnabled(false);
	actionBar.setHomeButtonEnabled(true);

	setContentView(R.layout.main);
	setBehindContentView(R.layout.task_lists);
	
	SlidingMenu sm = getSlidingMenu();
	sm.setShadowWidthRes(R.dimen.shadow_width);
	sm.setShadowDrawable(R.drawable.shadow);
	sm.setBehindOffsetRes(R.dimen.slidingmenu_offset);
	sm.setFadeDegree(0.35f);
	sm.setTouchModeAbove(SlidingMenu.TOUCHMODE_MARGIN);
	setSlidingActionBarEnabled(false);
	
	actionBar.setIcon(R.drawable.ic_drawer);
	actionBar.show();
	
	View view = getLayoutInflater().inflate(R.layout.about_dialog, null);
	AlertDialog.Builder builder = new AlertDialog.Builder(this);
	builder.setView(view).setTitle(getResources().getString(R.string.menu_item_about)).setPositiveButton(android.R.string.ok, null);
	aboutDialog = builder.create();

       Intent intent = getIntent();
       if (Intent.ACTION_SEARCH.equals(intent.getAction()))
           handleSearchIntent(intent);
       if (Intent.ACTION_SEND.equals(intent.getAction()) && intent.getType() != null
               && "text/plain".equals(intent.getType()))
           handleSendText(intent);
}
 
开发者ID:danielebufarini,项目名称:Reminders,代码行数:38,代码来源:Reminders.java

示例9: onCreate

import com.jeremyfeinstein.slidingmenu.lib.SlidingMenu; //导入方法依赖的package包/类
@Override
public void onCreate(Bundle savedInstanceState) {
	super.onCreate(savedInstanceState);

	setTitle(mTitleRes);
	

	// seta o menu lateral
	setBehindContentView(R.layout.menu_1);
	if (savedInstanceState == null) {
		FragmentTransaction t = this.getSupportFragmentManager().beginTransaction();
		mFrag = new Left_Menu();
		t.replace(R.id.menu_frame, mFrag);
		t.commit();
	} else {
		mFrag = (Fragment)this.getSupportFragmentManager().findFragmentById(R.id.menu_frame);
	}

	// customizando o menu, sombras, dimensões
	SlidingMenu sm = getSlidingMenu();
	sm.setShadowWidthRes(R.dimen.shadow_width);
	sm.setShadowDrawable(R.drawable.shadow);
	sm.setBehindOffsetRes(R.dimen.slidingmenu_offset);
	sm.setFadeDegree(0.35f);
	sm.setTouchModeAbove(SlidingMenu.TOUCHMODE_FULLSCREEN);

	getActionBar().setDisplayHomeAsUpEnabled(true);
}
 
开发者ID:Paulocajr,项目名称:IPRJapp,代码行数:29,代码来源:BaseActivity.java

示例10: onCreate

import com.jeremyfeinstein.slidingmenu.lib.SlidingMenu; //导入方法依赖的package包/类
@Override
public void onCreate(Bundle savedInstanceState) {
	super.onCreate(savedInstanceState);
	setTitle(R.string.responsive_ui);

	setContentView(R.layout.responsive_content_frame);

	// check if the content frame contains the menu frame
	if (findViewById(R.id.menu_frame) == null) {
		setBehindContentView(R.layout.menu_frame);
		getSlidingMenu().setSlidingEnabled(true);
		getSlidingMenu().setTouchModeAbove(SlidingMenu.TOUCHMODE_FULLSCREEN);
		// show home as up so we can toggle
		getSupportActionBar().setDisplayHomeAsUpEnabled(true);
	} else {
		// add a dummy view
		View v = new View(this);
		setBehindContentView(v);
		getSlidingMenu().setSlidingEnabled(false);
		getSlidingMenu().setTouchModeAbove(SlidingMenu.TOUCHMODE_NONE);
	}

	// set the Above View Fragment
	if (savedInstanceState != null)
		mContent = getSupportFragmentManager().getFragment(savedInstanceState, "mContent");
	if (mContent == null)
		mContent = new BirdGridFragment(0);	
	getSupportFragmentManager()
	.beginTransaction()
	.replace(R.id.content_frame, mContent)
	.commit();

	// set the Behind View Fragment
	getSupportFragmentManager()
	.beginTransaction()
	.replace(R.id.menu_frame, new BirdMenuFragment())
	.commit();

	// customize the SlidingMenu
	SlidingMenu sm = getSlidingMenu();
	sm.setBehindOffsetRes(R.dimen.slidingmenu_offset);
	sm.setShadowWidthRes(R.dimen.shadow_width);
	sm.setShadowDrawable(R.drawable.shadow);
	sm.setBehindScrollScale(0.25f);
	sm.setFadeDegree(0.25f);

	// show the explanation dialog
	if (savedInstanceState == null)
		new AlertDialog.Builder(this)
		.setTitle(R.string.what_is_this)
		.setMessage(R.string.responsive_explanation)
		.show();
}
 
开发者ID:JoeSteven,项目名称:Moring-Alarm,代码行数:54,代码来源:ResponsiveUIActivity.java

示例11: onCreate

import com.jeremyfeinstein.slidingmenu.lib.SlidingMenu; //导入方法依赖的package包/类
@Override
public void onCreate(Bundle savedInstanceState) {
	super.onCreate(savedInstanceState);
	setTitle(R.string.responsive_ui);

	setContentView(R.layout.responsive_content_frame);

	// check if the content frame contains the menu frame
	if (findViewById(R.id.menu_frame) == null) {
		setBehindContentView(R.layout.menu_frame);
		getSlidingMenu().setSlidingEnabled(true);
		getSlidingMenu().setTouchModeAbove(SlidingMenu.TOUCHMODE_FULLSCREEN);
		// show home as up so we can toggle
		getActionBar().setDisplayHomeAsUpEnabled(true);
	} else {
		// add a dummy view
		View v = new View(this);
		setBehindContentView(v);
		getSlidingMenu().setSlidingEnabled(false);
		getSlidingMenu().setTouchModeAbove(SlidingMenu.TOUCHMODE_NONE);
	}

	// set the Above View Fragment
	if (savedInstanceState != null)
		mContent = getSupportFragmentManager().getFragment(savedInstanceState, "mContent");
	if (mContent == null)
		mContent = new BirdGridFragment(0);	
	getSupportFragmentManager()
	.beginTransaction()
	.replace(R.id.content_frame, mContent)
	.commit();

	// set the Behind View Fragment
	getSupportFragmentManager()
	.beginTransaction()
	.replace(R.id.menu_frame, new BirdMenuFragment())
	.commit();

	// customize the SlidingMenu
	SlidingMenu sm = getSlidingMenu();
	sm.setBehindOffsetRes(R.dimen.slidingmenu_offset);
	sm.setShadowWidthRes(R.dimen.shadow_width);
	sm.setShadowDrawable(R.drawable.shadow);
	sm.setBehindScrollScale(0.25f);
	sm.setFadeDegree(0.25f);

	// show the explanation dialog
	if (savedInstanceState == null)
		new AlertDialog.Builder(this)
		.setTitle(R.string.what_is_this)
		.setMessage(R.string.responsive_explanation)
		.show();
}
 
开发者ID:JoeSteven,项目名称:Moring-Alarm,代码行数:54,代码来源:ResponsiveUIActivity.java

示例12: onCreate

import com.jeremyfeinstein.slidingmenu.lib.SlidingMenu; //导入方法依赖的package包/类
@Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        EventBus.getDefault().register(this);
        if (new SpTool(this, SpTool.SP_SETTING).getBoolean("moon", false)) {
            BaseApplication.sDefaultImageDrawable = R.drawable.z_iv_default_y;
            setTheme(R.style.ActivityThemeMoon);
        } else {
            BaseApplication.sDefaultImageDrawable = R.drawable.z_iv_default;
            setTheme(R.style.ActivityTheme);
        }
        // set the Above View
        if (savedInstanceState != null) {
            mFragmentMainHome = (FragmentMainHome) getSupportFragmentManager().getFragment(savedInstanceState, "mFragmentMainHome");
        }
        if (mFragmentMainHome == null) {
            mFragmentMainHome = new FragmentMainHome();
            mFragmentMainHome.setArguments(getIntent().getExtras());
        }
        setContentView(R.layout.activity_main_sliding);
        getSupportFragmentManager().beginTransaction()
                .replace(R.id.content_frame, mFragmentMainHome)
                .commit();

        // set the Behind View
        setBehindContentView(R.layout.v_layout_sliding_menu);
        if (savedInstanceState != null) {
            mFragmentSlidingMenu = (FragmentSlidingMenu) this.getSupportFragmentManager().findFragmentById(R.id.menu_frame);
        }
        if (mFragmentSlidingMenu == null) {
            mFragmentSlidingMenu = new FragmentSlidingMenu();
            getSupportFragmentManager().beginTransaction()
                    .replace(R.id.menu_frame, mFragmentSlidingMenu)
                    .commit();
        }

        // customize the SlidingMenu
        SlidingMenu sm = getSlidingMenu();
        sm.setShadowWidthRes(R.dimen.slidingmenu_shadow_width);
        sm.setShadowDrawable(R.drawable.v_sliding_menu_shadow);
        sm.setBehindOffset(ScreenTools.getScreenParams(this).width * 3 / 10);
        sm.setFadeDegree(0.35f);
        //设置触摸方式,必须为 TOUCHMODE_FULLSCREEN(全屏可触摸),TOUCHMODE_MARGIN(边缘可触摸),默认 48dp, TOUCHMODE_NONE(不可触摸)三者之一
        sm.setTouchModeAbove(SlidingMenu.TOUCHMODE_MARGIN);
        //动画效果
        sm.setBehindScrollScale(0.0f);
        sm.setBackgroundColor(Color.parseColor("#252525"));
        sm.setBehindCanvasTransformer(getTransformer(1));

//		getSupportActionBar().setDisplayHomeAsUpEnabled(true);
    }
 
开发者ID:BigAppOS,项目名称:BigApp_WordPress_Android,代码行数:52,代码来源:ActivityMainSliding.java

示例13: onCreate

import com.jeremyfeinstein.slidingmenu.lib.SlidingMenu; //导入方法依赖的package包/类
@Override
protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);

    setContentView(R.layout.activity_home);
    mTitle = getTitle();

    /* sliding menu with both right and left drawer */
    slidingMenu = new SlidingMenu(this);
    slidingMenu.setShadowWidthRes(R.dimen.shadow_width);
    slidingMenu.setShadowDrawable(R.drawable.shadow);
    slidingMenu.setBehindOffsetRes(R.dimen.slidingmenu_offset);
    slidingMenu.setFadeDegree(0.35f);
    slidingMenu.setTouchModeAbove(SlidingMenu.TOUCHMODE_FULLSCREEN);
    slidingMenu.setMode(SlidingMenu.LEFT_RIGHT);
    slidingMenu.setMenu(R.layout.slidingmenu_navigation_drawer);
    slidingMenu.setSecondaryMenu(R.layout.slidingmenu_network_drawer);
    slidingMenu.setSecondaryShadowDrawable(R.drawable.shadowright);
    if (savedInstanceState == null) {
        mNavigationDrawerFragment = new FragmentNavigationDrawer();
        mNetworkDrawerFragment    = new FragmentNetworkDrawer();
        this.getSupportFragmentManager().beginTransaction()
                .replace(R.id.navigation_drawer_frame, mNavigationDrawerFragment).commit();
        this.getSupportFragmentManager().beginTransaction()
                .replace(R.id.network_drawer_frame, mNetworkDrawerFragment).commit();
    } else {
        mNavigationDrawerFragment = (FragmentNavigationDrawer) this.getSupportFragmentManager().findFragmentById(R.id.navigation_drawer_frame);
        mNetworkDrawerFragment = (FragmentNetworkDrawer) this.getSupportFragmentManager().findFragmentById(R.id.network_drawer_frame);
    }
    slidingMenu.attachToActivity(this, SlidingMenu.SLIDING_WINDOW);

    /*
     * the tablayout for status and chat message with a viewpager.
     * note that we cannot swipe views with the viewpager as the swipe
     * gesture is catched by slidingmenu to slide the panel
     */
    TabLayout tabLayout = (TabLayout) findViewById(R.id.home_tab_layout);
    viewPager = (ViewPager) findViewById(R.id.home_viewpager);
    pagerAdapter = new HomePagerAdapter(getSupportFragmentManager());
    viewPager.setAdapter(pagerAdapter);
    viewPager.addOnPageChangeListener(onPageChangeListener);
    tabLayout.setupWithViewPager(viewPager);

    // little hack to set the icons instead of text
    notifStatus = renderTabView(this, R.drawable.ic_world,  (ViewGroup)tabLayout.getParent());
    notifChat   = renderTabView(this, R.drawable.ic_forum_white_24dp, (ViewGroup)tabLayout.getParent());
    tabLayout.getTabAt(0).setCustomView(notifStatus);
    tabLayout.getTabAt(1).setCustomView(notifChat);
    tabLayout.setSelectedTabIndicatorHeight(10);

    // for notification
    refreshStatusNotifications();
    refreshChatNotifications();
    EventBus.getDefault().register(this);
}
 
开发者ID:Marlinski,项目名称:Rumble,代码行数:56,代码来源:HomeActivity.java

示例14: initsm

import com.jeremyfeinstein.slidingmenu.lib.SlidingMenu; //导入方法依赖的package包/类
private void initsm() {
	// set the Behind View
	setBehindContentView(R.layout.menu_frame);

	getSupportFragmentManager().beginTransaction()
			.replace(R.id.menu_frame, new LeftBottomFragment()).commit();
	
	
	
	//getSupportFragmentManager().beginTransaction().replace(R.id.menu_frame, new LeftBottomFragment(), "TAG").commit();

	// customize the SlidingMenu
	SlidingMenu sm = getSlidingMenu();
	sm.setShadowWidthRes(R.dimen.shadow_width);
	sm.setShadowDrawable(R.drawable.shadow);
	sm.setBehindOffsetRes(R.dimen.slidingmenu_offset);
	sm.setFadeDegree(0.35f);
	sm.setTouchModeAbove(SlidingMenu.TOUCHMODE_FULLSCREEN);
	
	
	
}
 
开发者ID:leerduo,项目名称:travelinfo,代码行数:23,代码来源:MainActivity.java


注:本文中的com.jeremyfeinstein.slidingmenu.lib.SlidingMenu.setShadowDrawable方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。