Esempio n. 1
0
        // Connect pins

        private void CommandConnectPins_CanExecute(object sender, CanExecuteRoutedEventArgs e)
        {
            ConnectPinsParameters xcp = e.Parameter as ConnectPinsParameters;

            e.CanExecute = e.Parameter is ConnectPinsParameters cp &&
                           GraphUtil.CanConnectNodePins(cp.PinA.Pin, cp.PinB.Pin,
                                                        (a, b) => ProjectVM.Instance.ReflectionProvider.TypeSpecifierIsSubclassOf(a, b));
        }