void combinedContainerControl_FocusedControlChangedEvent(CombinedContainerControl containerControl, CommonBaseControl control) { WinFormsHelper.BeginFilteredManagedInvoke(this, TimeSpan.FromMilliseconds(250), new GeneralHelper.GenericDelegate<PlatformComponent>(UpdateFormText), control != null ? control.Tag as PlatformComponent : null); }
void combinedContainerControl_ContainedControlRemovedEvent(CombinedContainerControl container, Control control) { PlatformComponent component = null; // First, catch the component before uninitializing the control. if (_platform != null && control.Tag != null && control is PlatformComponentControl && _platform.GetComponentByIdentification((((PlatformComponentControl)control).Component).SubscriptionClientID.Id, true) != null) { component = ((PlatformComponentControl)control).Component; ((PlatformComponentControl)control).SetApplicationStatusStrip(null); } if (control is CommonBaseControl) { (control as CommonBaseControl).SaveState(); } if (component != null) {// Remove component from platform. if (_platform.IsMandatoryComponent(component) == false) { _platform.UnRegisterComponent(component); } component.UISerializationInfo.AddValue("componentVisible", false); } if (control is CommonBaseControl) { (control as CommonBaseControl).UnInitializeControl(); } UpdateComponentsMenues(); }