ComponentFactory.Krypton.Ribbon.ViewRibbonManager.Layout C# (CSharp) Method

Layout() public method

Perform a layout of the view.
public Layout ( ViewLayoutContext context ) : void
context ComponentFactory.Krypton.Toolkit.ViewLayoutContext View context for layout operation.
return void
        public override void Layout(ViewLayoutContext context)
        {
            // Prevent reentrancy
            if (!_layingOut)
            {
                Form ownerForm = _ribbon.FindForm();

                // We do not need to layout if inside a control that is minimized or if we are not inside a form at all
                if ((ownerForm == null) || ((ownerForm != null) && (ownerForm.WindowState == FormWindowState.Minimized)))
                    return;

                _layingOut = true;

                // Update the calculate values used during layout calls
                _ribbon.CalculatedValues.Recalculate();

                // Let base class perform standard layout actions
                base.Layout(context);

                _layingOut = false;
            }
        }