集合视图箭头按钮会更改每个重新加载的数据,这会导致不相等

问题描述

编辑问题- 在情节提要中,uibutton的图像会根据选定状态和认状态而变化,甚至在加载时,并非所有按钮看起来都相同

    *@IBAction func topButtonTouched(_ sender: UIButton) {
        
        if let delegate = self.delegate{
            delegate.topButtonTouched(indexPath: indexPath)}

    }
}
    here is the expend option

      func topButtonTouched(indexPath: IndexPath) {
        if(screenType == .parameters){
        isExpanded[indexPath.row] = !isExpanded[indexPath.row]
        }else{
            isExpanedErrors[indexPath.row] = !isExpanedErrors[indexPath.row]
        }
       
       
    //    let cell = self.collectionView.cellForItem(at: indexPath) as! ExpendeableCollectionViewCell
        
        UIView.animate(withDuration: 0.8,delay: 0.0,usingSpringWithdamping: 0.9,initialSpringVeLocity: 0.9,options: UIViewAnimationoptions.curveEaseInOut,animations: {
        },completion: {
            success in
            self.collectionView.reloadItems(at: [indexPath])
        
        })
    }*

[1]: https://i.stack.imgur.com/BAoPO.png

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)