mirror of
				https://github.com/568071718/creator-collection-view
				synced 2025-11-04 13:25:29 +00:00 
			
		
		
		
	获取widget组件容错处理
This commit is contained in:
		@@ -574,7 +574,7 @@ export class YXCollectionView extends Component {
 | 
			
		||||
 | 
			
		||||
            let transform = content.getComponent(UITransform) || content.addComponent(UITransform)
 | 
			
		||||
            transform.contentSize = this.node.getComponent(UITransform).contentSize
 | 
			
		||||
            this.getComponent(Widget).updateAlignment?.();
 | 
			
		||||
            this.getComponent(Widget)?.updateAlignment?.();
 | 
			
		||||
            result.content = content
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user