Exemplo n.º 1
0
 private void SelectionOnCollectionChanged(object sender, System.Collections.Specialized.NotifyCollectionChangedEventArgs e)
 {
     CreateGroupCommand.RaiseCanExecuteChanged();
     AddToGroupCommand.RaiseCanExecuteChanged();
     UngroupCommand.RaiseCanExecuteChanged();
     PinToNodeCommand.RaiseCanExecuteChanged();
 }
Exemplo n.º 2
0
 private void SelectionOnCollectionChanged(object sender, NotifyCollectionChangedEventArgs e)
 {
     CreateGroupCommand.RaiseCanExecuteChanged();
     AddToGroupCommand.RaiseCanExecuteChanged();
     UngroupCommand.RaiseCanExecuteChanged();
     ToggleIsFrozenCommand.RaiseCanExecuteChanged();
     RaisePropertyChanged("IsFrozenExplicitly");
     RaisePropertyChanged("CanToggleFrozen");
 }
        public void AddToGroupCommand()
        {
            Assert.AreNotEqual(Group.transform, Ribbon.transform.parent);
            ICommand addCommand = new AddToGroupCommand(Group, Ribbon);

            Invoker.ExecuteCommand(addCommand);
            Assert.AreEqual(Group, Ribbon.ParentGroup);
            Assert.AreEqual(Group.transform, Ribbon.transform.parent);
        }
        public void RemoveFromGroupCommand_WithActiveSketchWorld()
        {
            Assert.AreNotEqual(Group.transform, Ribbon.transform.parent);
            ICommand addCommand = new AddToGroupCommand(Group, Ribbon);

            Invoker.ExecuteCommand(addCommand);

            ICommand removeCommand = new RemoveFromGroupCommand(Ribbon);

            Invoker.ExecuteCommand(removeCommand);

            Assert.IsTrue(Ribbon.ParentGroup.transform.IsChildOf(SketchWorld.ActiveSketchWorld.transform));
        }
        public void RemoveFromGroupCommand()
        {
            SketchWorld.ActiveSketchWorld = null;
            Assert.AreNotEqual(Group.transform, Ribbon.transform.parent);
            ICommand addCommand = new AddToGroupCommand(Group, Ribbon);

            Invoker.ExecuteCommand(addCommand);

            ICommand removeCommand = new RemoveFromGroupCommand(Ribbon);

            Invoker.ExecuteCommand(removeCommand);

            Assert.AreEqual(null, Ribbon.ParentGroup);
            Assert.AreEqual(null, Ribbon.transform.parent);
        }
Exemplo n.º 6
0
 private void SelectionOnCollectionChanged(object sender, NotifyCollectionChangedEventArgs e)
 {
     CreateGroupCommand.RaiseCanExecuteChanged();
     AddToGroupCommand.RaiseCanExecuteChanged();
     UngroupCommand.RaiseCanExecuteChanged();
 }