public void ShowSubForm(string _type) { //sets program to SubForm mode, darkens screen and displays flating form. //Start by giving type of Form class. Implement interface SubForms.UI_SubForm for Cancel/Ok buttons //See DummySubForm for example if (spForm != null) { CloseSubForm(); } spForm = new UI_ShadowPanel(thisForm, _type); spForm.TopLevel = false; thisForm.Controls.Add(spForm); spForm.Show(); spForm.BringToFront(); }
public void OpenSubForm(ISubForm reqForm, bool lockSidebar = false) { //sets program to SubForm mode, darkens screen and displays flating form. //Start by giving type of Form class. Implement interface SubForms.UI_SubForm for Cancel/Ok buttons //See DummySubForm for example if (lockSidebar) { S.GET <UI_CoreForm>().LockSideBar(); } if (spForm != null) { CloseSubForm(); } spForm = new UI_ShadowPanel(this, reqForm); spForm.TopLevel = false; this.Controls.Add(spForm); spForm.Show(); spForm.BringToFront(); }