public static void SetAttachedValue(Binding.BindableObject bindable, Binding.BindableProperty property, object value) { if (bindable == null) { throw new ArgumentNullException(nameof(bindable)); } bindable.SetValueCore(property, value, SetValueFlags.None, SetValuePrivateFlags.ManuallySet, false); }
public static T GetAttachedValue <T>(Binding.BindableObject bindable, Binding.BindableProperty property) { if (bindable == null) { throw new ArgumentNullException(nameof(bindable)); } return((T)bindable.GetValue(property)); }
internal static void OnChildPropertyChanged(Binding.BindableObject bindable, object oldValue, object newValue) { // Unused parameters _ = oldValue; _ = newValue; View view = bindable as View; view?.Layout?.RequestLayout(); }
internal static void SetChildValue(Binding.BindableObject bindable, Binding.BindableProperty property, object value) { bindable.SetValueCore(property, value, SetValueFlags.None, SetValuePrivateFlags.ManuallySet, false); }
static void BindingContextPropertyChanged(BindableObject bindable, object oldvalue, object newvalue) { bindable._inheritedContext = null; bindable.ApplyBindings(skipBindingContext: true, fromBindingContextChanged: true); bindable.OnBindingContextChanged(); }
internal override bool GetState(BindableObject bindable) { return((bool)bindable.GetValue(_stateProperty)); }
internal override void TearDown(BindableObject bindable) { bindable.ClearValue(_stateProperty); bindable.PropertyChanged -= OnAttachedObjectPropertyChanged; }