Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SlidingTabLayout.setOnTabSelectListener错误 只有点击事件 没有滚动事件 #539

Open
surpreme opened this issue Dec 7, 2021 · 0 comments

Comments

@surpreme
Copy link

surpreme commented Dec 7, 2021

SlidingTabLayout.setOnTabSelectListener错误 只有点击事件 没有滚动事件
目前只有以下代码调用
tabView.setOnClickListener(new OnClickListener() {
@OverRide
public void onClick(View v) {
int position = mTabsContainer.indexOfChild(v);
if (position != -1) {
if (mViewPager.getCurrentItem() != position) {
if (mSnapOnTabClick) {
mViewPager.setCurrentItem(position, false);
} else {
mViewPager.setCurrentItem(position);
}

                    if (mListener != null) {
                        mListener.onTabSelect(position);
                    }
                } else {
                    if (mListener != null) {
                        mListener.onTabReselect(position);
                    }
                }
            }
        }
    }); @H07000223 
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant