コード例 #1
0
        private void RemovePoint()
        {
            if (GenericPoints.Count == 0)
            {
                return;
            }

            Whiskers.RemoveAt(Whiskers.Count - 1);
            GenericPoints.RemoveAt(GenericPoints.Count - 1);

            OkCommand.RaiseCanExecuteChangedNotification();
            RemovePointCommand.RaiseCanExecuteChangedNotification();
        }
コード例 #2
0
        private void AddPoint()
        {
            IWhiskerClipSettings whisker = ModelResolver.Resolve <IWhiskerClipSettings>();

            whisker.IsGenericPoint = true;
            whisker.NumberOfPoints = 1;
            int genericStartId = ViewModel.NumberOfWhiskers + 1;

            genericStartId     += GenericPoints.Count;
            whisker.WhiskerId   = genericStartId;
            whisker.WhiskerName = "Point " + (GenericPoints.Count + 1);
            AddWhisker(whisker);
            GenericPoints.Add(whisker);
            RemovePointCommand.RaiseCanExecuteChangedNotification();
        }