public static UpsightData FromJson(string json) { UpsightData upsightData = new UpsightData(); upsightData.populateFromJson(json); return(upsightData); }
private void billboardDidReceiveData(string json) { if (UpsightManager.billboardDidReceiveDataEvent == null) { return; } UpsightManager.billboardDidReceiveDataEvent(UpsightData.FromJson(json)); }
public void nativeMessageDismissed() { ((Component)this.BackgroundPanel).get_gameObject().SetActive(false); this._showingNativeMessage = false; this._upsightData.RecordClickEvent(); this._upsightData.RecordDismissEvent(); this._upsightData.Destroy(); this._upsightData = (UpsightData)null; }
private void billboardDidReceiveDataEvent(UpsightData data) { this._upsightData = data; ((Graphic)this.BackgroundPanel).set_color(data.GetColor("BGColor")); this.ButtonText.set_text(data.GetString("BodyCopy")); Texture2D texture2D1 = new Texture2D(1, 1); texture2D1.LoadImage(File.ReadAllBytes(data.GetImage("OfferImage").ImagePath)); this.OfferImage.set_sprite(Sprite.Create(texture2D1, new Rect(0.0f, 0.0f, (float)((Texture)texture2D1).get_width(), (float)((Texture)texture2D1).get_height()), Vector2.get_zero())); Texture2D texture2D2 = new Texture2D(1, 1); texture2D2.LoadImage(File.ReadAllBytes(data.GetImage("OrnamentImage").ImagePath)); this.OrnamentImage.set_sprite(Sprite.Create(texture2D2, new Rect(0.0f, 0.0f, (float)((Texture)texture2D2).get_width(), (float)((Texture)texture2D2).get_height()), Vector2.get_zero())); this._showingNativeMessage = true; ((Component)this.BackgroundPanel).get_gameObject().SetActive(true); }
private void billboardDidReceiveDataEvent(UpsightData data) { Debug.Log((object)("billboardDidReceiveDataEvent: " + (object)data)); }