public void LaunchRoutedEvent(IUILogicalNode Launcher, BubbleEventArgs args) { foreach (IUILogicalNode node in GetUINode(Launcher, args.RoutingStrategy)) { if (args.RoutingState == RoutingState.Handled) { break; } //node.HandleRoutedEvent(args); } RoutedEventOver(); }
public void Binding(UIBehaviour uiComponent, UIBindingComponent uiToken, IUILogicalNode target) { text = uiComponent as Text; string path = uiComponent.name; if (uiToken.AttributeTokens.Where(p => p.attribute == "Text").Count() > 0) { path = uiToken.AttributeTokens.Where(p => p.attribute == "Text").First().path; } else if (!string.IsNullOrEmpty(uiToken.componentToken)) { path = uiToken.componentToken; } else if (!string.IsNullOrEmpty(uiToken.gameObject.GetComponent <IUINode>().NodeToken)) { target.DataContext.BindingComponent(uiToken.gameObject.GetComponent <IUINode>().NodeToken, this); } target.DataContext.BindingComponent(path, this); text.text = target.DataContext.GetData(path) as string; }
public void Binding(UIBehaviour uiComponent, UIBindingComponent bindingComponent, IUILogicalNode target) { Text = uiComponent as Text; string path = bindingComponent.GetBindingPath("Text"); target.BindingComponent(path, this); Text.text = target.DataContext.GetData(path) as string; }
public void Binding(UIBehaviour uiComponent, UIBindingComponent bindingComponent, IUILogicalNode target) { button = uiComponent as Button; button.onClick.AddListener(() => { target.ExecuteCommand(bindingComponent.GetBindingPath("OnClick"), null); }); }
public void RedirectionRoutedEvent(IUILogicalNode redirector, BubbleEventArgs args) { }
public void Binding(UIBehaviour uiComponent, UIBindingComponent bindingComponent, IUILogicalNode target) { tmpro = uiComponent as TextMeshProUGUI; string path = bindingComponent.GetBindingPath("TMPro"); target.BindingComponent(path, this); tmpro.text = target.DataContext.GetData(path) as string; }