private void TriggerPagination() { Vent.Trigger(new PaginationEvent { Key = ventKey, AdvancePages = advancePages }); }
protected override void Awake() { base.Awake(); var button = GetComponent <Button>(); button.onClick.AddListener(() => { Vent.Trigger(new PartSelectedEvent { PartSelector = this }); }); }
protected override void Awake() { base.Awake(); var button = GetComponent <Button>(); button.onClick.AddListener(() => { var evt = new UIComponentEvent { Component = this }; Vent.Trigger(key, evt); }); }
public void OnPointerClick(PointerEventData eventData) { if (eventData.button == PointerEventData.InputButton.Left) { Vent.Trigger(new SelectColorPickerPresetEvent { Key = key, Id = id, Color = color, }); } else if (eventData.button == PointerEventData.InputButton.Right) { Vent.Trigger(new RemoveColorPickerPresetEvent { Key = key, Id = id, }); } }
private void DisplayDollChoices <T>(IReadOnlyCollection <T> choices) where T : DollPart { var choiceGos = new List <GameObject>(choices.Count + 1); var nullSelectorGo = Instantiate(protoNullPartSelector); var nullSelector = nullSelectorGo.GetComponent <PartSelector>(); nullSelector.masterCanvas = masterCanvas; choiceGos.Add(nullSelectorGo); foreach (var choice in choices) { var selectorGo = Instantiate(protoPartSelector); var selector = selectorGo.GetComponent <PartSelector>(); selector.masterCanvas = masterCanvas; var part = staticParts[choice.Path]; selector.SetDollPart(part); choiceGos.Add(selectorGo); } Vent.Trigger(new SetItemsEvent { Items = choiceGos, Key = partSelectionKey }); }