예제 #1
0
        private void activatePatchingControl(ISetupPatchingControl control)
        {
            if (_currentPatchingControl != null)
            {
                _currentPatchingControl.FiltersAdded    -= control_FiltersAdded;
                _currentPatchingControl.PatchingUpdated -= control_PatchingUpdated;
            }

            _currentPatchingControl = control;

            control.FiltersAdded    += control_FiltersAdded;
            control.PatchingUpdated += control_PatchingUpdated;

            tableLayoutPanelPatchingSetup.Controls.Clear();
            tableLayoutPanelPatchingSetup.Controls.Add(control.SetupPatchingControl);


            if (_currentControllersControl == null)
            {
                control.UpdateControllerSelection(new ControllersAndOutputsSet());
            }
            else
            {
                control.UpdateControllerSelection(_currentControllersControl.SelectedControllersAndOutputs);
            }
            if (_currentElementControl == null)
            {
                control.UpdateElementSelection(Enumerable.Empty <Vixen.Sys.ElementNode>());
            }
            else
            {
                control.UpdateElementSelection(_currentElementControl.SelectedElements);
            }
        }
예제 #2
0
 void control_ControllerSelectionChanged(object sender, ControllerSelectionEventArgs e)
 {
     if (_currentPatchingControl != null)
     {
         _currentPatchingControl.UpdateControllerSelection(e.ControllersAndOutputs);
     }
 }
예제 #3
0
		private void activatePatchingControl(ISetupPatchingControl control)
		{
			if (_currentPatchingControl != null) {
				_currentPatchingControl.FiltersAdded-=  control_FiltersAdded;
				_currentPatchingControl.PatchingUpdated -= control_PatchingUpdated;
			}

			_currentPatchingControl = control;

			control.FiltersAdded += control_FiltersAdded;
			control.PatchingUpdated += control_PatchingUpdated;

			tableLayoutPanelPatchingSetup.Controls.Clear();
			tableLayoutPanelPatchingSetup.Controls.Add(control.SetupPatchingControl);


			if (_currentControllersControl == null) {
				control.UpdateControllerSelection(new ControllersAndOutputsSet());
			} else {
				control.UpdateControllerSelection(_currentControllersControl.SelectedControllersAndOutputs);				
			}
			if (_currentElementControl == null) {
				control.UpdateElementSelection(Enumerable.Empty<Vixen.Sys.ElementNode>());
			} else {
				control.UpdateElementSelection(_currentElementControl.SelectedElements);				
			}
		}