soarcn / BottomSheet

One way to present a set of actions to a user is with bottom sheets, a sheet of paper that slides up from the bottom edge of the screen. Bottom sheets offer flexibility in the display of clear and simple actions that do not need explanation.
http://soarcn.github.io/BottomSheet
2.22k stars 409 forks source link

菜单关闭回调监听无法正确回调 #54

Closed wuyexiong closed 9 years ago

wuyexiong commented 9 years ago

用中文可否

 @Override
        public void onViewDragStateChanged(int state) {
            if (mDragHelper.getViewDragState() == ViewDragHelper.STATE_IDLE && dismissed) {
                if (mListener != null) {
                    mListener.onClosed();
                }
            }
        }

看这一个判断. dismissed 在触摸事件Down的时候会变更dismissed的值为false. 所以.当我把菜单下滑消失..注意.并且在消失的时候点击了屏幕.那么 mListener.onClosed();就无法被回调到了.

soarcn commented 9 years ago

Good point, 稍后会修正的.