private void RenderUI(AbstractUI ui, bool forceDerender)
 {
     if (SettingsWindow.tabControlCore.SelectedTab == ui.Parent && !forceDerender)
     {
         ui.ResumeLayout(false);
         ui.Rerender();
     }
     else
     {
         ui.Derender();
         ui.SuspendLayout();
     }
 }
        private void Render(AbstractUI ui, bool IsDerenderRequest)
        {
            var grandParent = (TabControl)Parent.Parent;
            var parent      = (TabPage)Parent;

            if (!IsDerenderRequest && grandParent.SelectedTab == parent && tabControlCore.SelectedTab == ui.Parent)
            {
                ui.ResumeLayout(false);
                ui.Rerender();
            }
            else
            {
                ui.Derender();
                ui.SuspendLayout();
            }
        }