protected virtual InputBinding FindChordPattern(InputBindingsCollection list) { Chord runtimeChord = CreateRuntimeChord(); for (int i = 0; i < list.Count; i++) { if (runtimeChord.CompareTo(list[i].Chord) == 0) { if (list[i].CommandContext != null) { if (typeof(Control).IsAssignableFrom(list[i].CommandContext.GetType())) { if (!(list[i].CommandContext as Control).Disposing) //&&(list[i].CommandContext as Control).FindForm() != null { return(list[i]); } } if (typeof(RadItem).IsAssignableFrom(list[i].CommandContext.GetType())) { return(list[i]); } } } } return(null); }
protected virtual Chord FindChordPattern(Chord[] list) { Chord runtimeChord = this.CreateRuntimeChord(); for (int index = 0; index < list.Length; ++index) { if (runtimeChord.CompareTo((object)list[index]) == 0) { return(list[index]); } } return((Chord)null); }
protected virtual InputBinding FindChordPattern(InputBindingsCollection list) { Chord runtimeChord = this.CreateRuntimeChord(); for (int index = 0; index < list.Count; ++index) { if (runtimeChord.CompareTo((object)list[index].Chord) == 0 && list[index].CommandContext != null && (typeof(Control).IsAssignableFrom(list[index].CommandContext.GetType()) && !(list[index].CommandContext as Control).Disposing || typeof(RadItem).IsAssignableFrom(list[index].CommandContext.GetType()))) { return(list[index]); } } return((InputBinding)null); }
protected virtual Chord FindChordPattern(Chord[] list) { Chord runtimeChord = CreateRuntimeChord(); for (int i = 0; i < list.Length; i++) { if (runtimeChord.CompareTo(list[i]) == 0) { return(list[i]); } } return(null); }