在Android

时间:2017-06-15 10:37:42

标签: android slidingmenu

我的应用程序中有滑动菜单,我想从任何活动中打开抽屉。可以帮助我吗我可以打开滑动菜单b

  

在onSaveInstanceState之后无法执行此操作                                                                                    在   android.support.v4.app.FragmentManagerImpl.checkStateLoss(FragmentManager.java:1493)                                                                                    在   android.support.v4.app.FragmentManagerImpl.enqueueAction(FragmentManager.java:1511)                                                                                    在   android.support.v4.app.FragmentManagerImpl.popBackStack(FragmentManager.java:591)                                                                                    在   com.videobankdigital.vmr3.MainActivity_.getBottomFragment(MainActivity_.java:335)                                                                                    在   com.videobankdigital.vmr3.MainActivity_.switchContent(MainActivity_.java:97)                                                                                    在   com.videobankdigital.vmr3.SlidingPanelHelper.LeftSliderMenuFragment $ 1.onItemClick(LeftSliderMenuFragment.java:125)                                                                                    在android.widget.AdapterView.performItemClick(AdapterView.java:313)                                                                                    在android.widget.AbsListView.performItemClick(AbsListView.java:1163)                                                                                    在android.widget.AbsListView $ PerformClick.run(AbsListView.java:3112)                                                                                    在android.widget.AbsListView.onTouchUp(AbsListView.java:3913)                                                                                    在android.widget.AbsListView.onTouchEvent(AbsListView.java:3685)                                                                                    在android.view.View.dispatchTouchEvent(View.java:8725)                                                                                    在   android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2594)                                                                                    在android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2305)                                                                                    在   android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2606)                                                                                    在android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2320)                                                                                    在   android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2606)                                                                                    在android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2320)                                                                                    在   android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2606)                                                                                    在android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2320)                                                                                    在   android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2606)                                                                                    在android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2320)                                                                                    在   android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2606)                                                                                    在android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2320)                                                                                    在   android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2606)                                                                                    在android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2320)                                                                                    在   com.android.internal.policy.impl.PhoneWindow $ DecorView.superDispatchTouchEvent(PhoneWindow.java:2545)                                                                                    在   com.android.internal.policy.impl.PhoneWindow.superDispatchTouchEvent(PhoneWindow.java:1745)                                                                                    在android.app.Activity.dispatchTouchEvent(Activity.java:2834)                                                                                    在   android.support.v7.view.WindowCallbackWrapper.dispatchTouchEvent(WindowCallbackWrapper.java:60)                                                                                    在   com.android.internal.policy.impl.PhoneWindow $ DecorView.dispatchTouchEvent(PhoneWindow.java:2506)                                                                                    在android.view.View.dispatchPointerEvent(View.java:8915)                                                                                    在   android.view.ViewRootImpl $ ViewPostImeInputStage.processPointerEvent(ViewRootImpl.java:4098)                                                                                    在   android.view.ViewRootImpl $ ViewPostImeInputStage.onProcess(ViewRootImpl.java:3961)                                                                                    在   android.view.ViewRootImpl $ InputStage.deliver(ViewRootImpl.java:3523)                                                                                    在   android.view.ViewRootImpl $ InputStage.onDeliverToNext(ViewRootImpl.java:3576)                                                                                    在   android.view.ViewRootImpl $ InputStage.forward(ViewRootImpl.java:3542)                                                                                    在   android.view.ViewRootImpl $ AsyncInputStage.forward(ViewRootImpl.java:3652)                                                                                    在android.view.ViewRootImpl $ InputStage.apply(ViewRootImpl.java:3550)                                                                                    在   android.view.ViewRootImpl $ AsyncInputStage.apply(ViewRootImpl.java:3709)                                                                                    在   android.view.ViewRootImpl $ InputStage.deliver(ViewRootImpl.java:3523)                                                                                    在   android.view.ViewRootImpl $ InputStage.onDeliverToNext(ViewRootImpl.java:3576)                                                                                    在   android.view.ViewRootImpl $ InputStage.forward(ViewRootImpl.java:3542)                                                                                    在android.view.ViewRootImpl $ InputStage.apply(ViewRootImpl.java:3550)                                                                                    在   android.view.ViewRootImpl $ InputStage.deliver(ViewRootImpl.java:3523)                                                                                    在android.view.ViewRootImpl.deliverInputEvent(ViewRootImpl.java:5795)                                                                                    在   android.view.ViewRootImpl.doProcessInputEvents(ViewRootImpl.java:5769)                                                                                    在android.view.ViewRootImpl.enqueueInputEvent(ViewRootImpl.java:5740)                                                                                    在   android.view.ViewRootImpl $ WindowInputEventReceiver.onInputEvent(ViewRootImpl.java:5885)                                                                                    在   android.view.InputEventReceiver.dispatchInputEvent(InputEventReceiver.java:185)                                                                                    在android.os.MessageQueue.nativePollOnce(原生方法)

我使用了https://github.com/jfeinstein10/SlidingMenu这个

1 个答案:

答案 0 :(得分:1)

在一个基本活动中使用此滑动菜单,并将此活动扩展到您想要此滑动菜单的其他活动