// Token: 0x060048DD RID: 18653 RVA: 0x0014AB24 File Offset: 0x00148D24 internal static bool IsOneWay(BindingBase bindingBase) { if (bindingBase == null) { return(false); } Binding binding = bindingBase as Binding; if (binding != null) { return(binding.Mode == BindingMode.OneWay); } MultiBinding multiBinding = bindingBase as MultiBinding; if (multiBinding != null) { return(multiBinding.Mode == BindingMode.OneWay); } PriorityBinding priorityBinding = bindingBase as PriorityBinding; if (priorityBinding != null) { Collection <BindingBase> bindings = priorityBinding.Bindings; int count = bindings.Count; for (int i = 0; i < count; i++) { if (DataGridHelper.IsOneWay(bindings[i])) { return(true); } } } return(false); }
protected override bool OnCoerceIsReadOnly(bool baseValue) { if (DataGridHelper.IsOneWay(EffectiveBinding)) { return(true); } // only call the base if we dont want to force IsReadOnly true return(base.OnCoerceIsReadOnly(baseValue)); }
/// <summary>Determines the value of the <see cref="P:System.Windows.Controls.DataGridColumn.IsReadOnly" /> property based on property rules from the <see cref="T:System.Windows.Controls.DataGrid" /> that contains this column.</summary> /// <param name="baseValue">The value that was passed to the delegate.</param> /// <returns> /// <see langword="true" /> if the combo boxes in the column cannot be edited; otherwise, <see langword="false" />.</returns> // Token: 0x06004899 RID: 18585 RVA: 0x00149FCF File Offset: 0x001481CF protected override bool OnCoerceIsReadOnly(bool baseValue) { return(DataGridHelper.IsOneWay(this.EffectiveBinding) || base.OnCoerceIsReadOnly(baseValue)); }