ComponentFactory.Krypton.Ribbon.ViewDrawRibbonRecentShortcut.RenderBefore C# (CSharp) Method

RenderBefore() public method

Perform rendering before child elements are rendered.
public RenderBefore ( RenderContext context ) : void
context ComponentFactory.Krypton.Toolkit.RenderContext Rendering context.
return void
        public override void RenderBefore(RenderContext context)
        {
            Debug.Assert(context != null);

            // Validate incoming reference
            if (context == null) throw new ArgumentNullException("context");

            // Only draw the shortcut text if there is some defined
            string shortcut = Values.GetShortText();
            if (!string.IsNullOrEmpty(shortcut))
            {
                // Only draw shortcut if the shortcut is not equal to the fixed string 'A'
                if (!shortcut.Equals("A"))
                    base.RenderBefore(context);
            }
        }