//public ToolSheetPaneWPF() //{ // InitializeComponent(); //} public ToolSheetPaneWPF(IPluginCommunicationsInterface comms) { InitializeComponent(); oComm = comms; PowerMILLAutomation.SetVariables(oComm); // subscribe to some events comms.EventUtils.Subscribe(new EventSubscription("EntityCreated", EntityCreated)); comms.EventUtils.Subscribe(new EventSubscription("EntityDeleted", EntityDeleted)); comms.EventUtils.Subscribe(new EventSubscription("ProjectClosed", ProjectClosed)); comms.EventUtils.Subscribe(new EventSubscription("ProjectOpened", ProjectOpened)); comms.EventUtils.Subscribe(new EventSubscription("EntityRenamed", EntityRenamed)); LoadProjectComponents(); }
public static void SetVariables(IPluginCommunicationsInterface comms) { oPServices = comms.Services; oToken = comms.Token; }
/// <summary> /// new instance of the class /// </summary> /// <param name="comms"></param> public PowerMILLAutomation(IPluginCommunicationsInterface comms) { oPServices = comms.Services; oToken = comms.Token; }