viewBanner = (ViewPager) view.findViewById(R.id.banner); viewBannerIndicator = (CircleIndicator) view.findViewById(R.id.banner_indicator);
bannerAdapter = new BannerAdapter(); viewBanner.setAdapter(bannerAdapter); viewBanner.setOnTouchListener(new View.OnTouchListener() { @Override public boolean onTouch(View v, MotionEvent event) { switch (event.getAction()) { case MotionEvent.ACTION_DOWN:
//拖动时关闭自动滑动,防止计时器时间冲突 autoScrollBanner(false);