public void OnRegister(FieldTypeProviderProxy typeProviderProxy, Action<Field, Type> onFieldTypeChanged) { foreach (var drawer in _fieldToDrawer) { drawer.Value.OnRegister(typeProviderProxy, onFieldTypeChanged); } }
internal void OnRegister(FieldTypeProviderProxy typeProviderProxy, Action <Field, Type> onFieldTypeChanged) { _changeFieldTypeGenericMenu = new GenericMenu(); foreach (var type in typeProviderProxy.FieldTypeProviderData.Types) { var localType = type; _changeFieldTypeGenericMenu.AddItem(new GUIContent(type.Name), false, () => onFieldTypeChanged(_field, localType)); } }
public override void OnRegister() { base.OnRegister(); _fieldTypeProviderProxy = (FieldTypeProviderProxy)Facade.RetrieveProxy(FieldTypeProviderProxy.Name); _nodeFieldsDrawer.OnRegister(_fieldTypeProviderProxy, _onFieldTypeChanged); }
public void HandleFieldAddition(Field addedField, FieldTypeProviderProxy fieldTypeProviderProxy, Action<Field, Type> onFieldTypeChanged) { _fieldToDrawer[addedField] = new NodeSeparateFieldDrawer(addedField); _fieldToDrawer[addedField].OnRegister(fieldTypeProviderProxy, onFieldTypeChanged); }