// Token: 0x0600628A RID: 25226 RVA: 0x00232638 File Offset: 0x00230A38 public override void Setup(IUIGroupItemDatasource item, Action <IUIGroupItemDatasource> onItemSelected) { base.Setup(item, onItemSelected); this.blueprintImage.texture = null; this.apiWorld = (item as ApiWorld); this.apiAvatar = (item as ApiAvatar); string imageUrl = null; if (this.apiAvatar != null) { this.nameText.text = this.apiAvatar.name; imageUrl = this.apiAvatar.imageUrl; } if (this.apiWorld != null) { this.nameText.text = this.apiWorld.name; imageUrl = this.apiWorld.imageUrl; } Downloader.DownloadImage(imageUrl, delegate(string downloadedUrl, Texture2D image) { if (imageUrl == downloadedUrl) { this.blueprintImage.texture = image; } }, string.Empty); }
// Token: 0x06006174 RID: 24948 RVA: 0x00226514 File Offset: 0x00224914 public virtual void Setup(IUIGroupItemDatasource item, Action <IUIGroupItemDatasource> onItemSelected) { this.dataSource = item; this.button.onClick.RemoveAllListeners(); this.button.onClick.AddListener(delegate { if (onItemSelected != null) { onItemSelected(this.dataSource); } }); }