java.lang.IllegalStateException: The specified child already has a parent. You must call removeView() on the child's parent first.
指定的子级已经有父级。必须先对子级的父级调用removeview()
我是使用 RecycleView 加载 XBanner 滑动的时候就是报错 setData 方法 之前移除所以的视图即可。
holeder.xBanner.setData(imageArr, titleArr);
java.lang.IllegalStateException: The specified child already has a parent. You must call removeView() on the child's parent first.
holeder.xBanner.removeAllViews(); holeder.xBanner.setData(imageArr, titleArr);