public void HandleLayerButtonClick(ArItem item) { if (item != null && !IsEmpty(item.layerName) && !IsEmpty(item.url)) { Debug.Log("HandleLayerButtonClick " + item.itemName); RefreshRequest = new RefreshRequest { url = item.url, layerName = item.layerName, latitude = FixedDeviceLatitude, longitude = FixedDeviceLongitude }; } if (MenuEnabled.HasValue && MenuEnabled.Value) { HeaderButton.SetActive(_headerButtonActivated); MenuButton.SetActive(MenuEnabled.HasValue && MenuEnabled.Value); LayerPanel.SetActive(false); if (_layerScrollList != null) { _layerScrollList.RemoveButtons(); } } }
public void Setup(ArItem currentItem, ArBehaviourUserInterface behaviour) { _item = currentItem; nameLabel.text = _item.itemName; line2Label.text = _item.line2; line3Label.text = _item.distance + "m" + (string.IsNullOrEmpty(_item.line3) ? string.Empty : ", " + _item.line3); iconImage.sprite = _item.icon; _behaviour = behaviour; }