UnityEngine.GUISkin.BuildStyleCache C# (CSharp) Method

BuildStyleCache() private method

private BuildStyleCache ( ) : void
return void
        private void BuildStyleCache()
        {
            if (this.m_box == null)
            {
                this.m_box = new GUIStyle();
            }
            if (this.m_button == null)
            {
                this.m_button = new GUIStyle();
            }
            if (this.m_toggle == null)
            {
                this.m_toggle = new GUIStyle();
            }
            if (this.m_label == null)
            {
                this.m_label = new GUIStyle();
            }
            if (this.m_window == null)
            {
                this.m_window = new GUIStyle();
            }
            if (this.m_textField == null)
            {
                this.m_textField = new GUIStyle();
            }
            if (this.m_textArea == null)
            {
                this.m_textArea = new GUIStyle();
            }
            if (this.m_horizontalSlider == null)
            {
                this.m_horizontalSlider = new GUIStyle();
            }
            if (this.m_horizontalSliderThumb == null)
            {
                this.m_horizontalSliderThumb = new GUIStyle();
            }
            if (this.m_verticalSlider == null)
            {
                this.m_verticalSlider = new GUIStyle();
            }
            if (this.m_verticalSliderThumb == null)
            {
                this.m_verticalSliderThumb = new GUIStyle();
            }
            if (this.m_horizontalScrollbar == null)
            {
                this.m_horizontalScrollbar = new GUIStyle();
            }
            if (this.m_horizontalScrollbarThumb == null)
            {
                this.m_horizontalScrollbarThumb = new GUIStyle();
            }
            if (this.m_horizontalScrollbarLeftButton == null)
            {
                this.m_horizontalScrollbarLeftButton = new GUIStyle();
            }
            if (this.m_horizontalScrollbarRightButton == null)
            {
                this.m_horizontalScrollbarRightButton = new GUIStyle();
            }
            if (this.m_verticalScrollbar == null)
            {
                this.m_verticalScrollbar = new GUIStyle();
            }
            if (this.m_verticalScrollbarThumb == null)
            {
                this.m_verticalScrollbarThumb = new GUIStyle();
            }
            if (this.m_verticalScrollbarUpButton == null)
            {
                this.m_verticalScrollbarUpButton = new GUIStyle();
            }
            if (this.m_verticalScrollbarDownButton == null)
            {
                this.m_verticalScrollbarDownButton = new GUIStyle();
            }
            if (this.m_ScrollView == null)
            {
                this.m_ScrollView = new GUIStyle();
            }
            this.m_Styles = new Dictionary<string, GUIStyle>(StringComparer.OrdinalIgnoreCase);
            this.m_Styles["box"] = this.m_box;
            this.m_box.name = "box";
            this.m_Styles["button"] = this.m_button;
            this.m_button.name = "button";
            this.m_Styles["toggle"] = this.m_toggle;
            this.m_toggle.name = "toggle";
            this.m_Styles["label"] = this.m_label;
            this.m_label.name = "label";
            this.m_Styles["window"] = this.m_window;
            this.m_window.name = "window";
            this.m_Styles["textfield"] = this.m_textField;
            this.m_textField.name = "textfield";
            this.m_Styles["textarea"] = this.m_textArea;
            this.m_textArea.name = "textarea";
            this.m_Styles["horizontalslider"] = this.m_horizontalSlider;
            this.m_horizontalSlider.name = "horizontalslider";
            this.m_Styles["horizontalsliderthumb"] = this.m_horizontalSliderThumb;
            this.m_horizontalSliderThumb.name = "horizontalsliderthumb";
            this.m_Styles["verticalslider"] = this.m_verticalSlider;
            this.m_verticalSlider.name = "verticalslider";
            this.m_Styles["verticalsliderthumb"] = this.m_verticalSliderThumb;
            this.m_verticalSliderThumb.name = "verticalsliderthumb";
            this.m_Styles["horizontalscrollbar"] = this.m_horizontalScrollbar;
            this.m_horizontalScrollbar.name = "horizontalscrollbar";
            this.m_Styles["horizontalscrollbarthumb"] = this.m_horizontalScrollbarThumb;
            this.m_horizontalScrollbarThumb.name = "horizontalscrollbarthumb";
            this.m_Styles["horizontalscrollbarleftbutton"] = this.m_horizontalScrollbarLeftButton;
            this.m_horizontalScrollbarLeftButton.name = "horizontalscrollbarleftbutton";
            this.m_Styles["horizontalscrollbarrightbutton"] = this.m_horizontalScrollbarRightButton;
            this.m_horizontalScrollbarRightButton.name = "horizontalscrollbarrightbutton";
            this.m_Styles["verticalscrollbar"] = this.m_verticalScrollbar;
            this.m_verticalScrollbar.name = "verticalscrollbar";
            this.m_Styles["verticalscrollbarthumb"] = this.m_verticalScrollbarThumb;
            this.m_verticalScrollbarThumb.name = "verticalscrollbarthumb";
            this.m_Styles["verticalscrollbarupbutton"] = this.m_verticalScrollbarUpButton;
            this.m_verticalScrollbarUpButton.name = "verticalscrollbarupbutton";
            this.m_Styles["verticalscrollbardownbutton"] = this.m_verticalScrollbarDownButton;
            this.m_verticalScrollbarDownButton.name = "verticalscrollbardownbutton";
            this.m_Styles["scrollview"] = this.m_ScrollView;
            this.m_ScrollView.name = "scrollview";
            if (this.m_CustomStyles != null)
            {
                for (int i = 0; i < this.m_CustomStyles.Length; i++)
                {
                    if (this.m_CustomStyles[i] != null)
                    {
                        this.m_Styles[this.m_CustomStyles[i].name] = this.m_CustomStyles[i];
                    }
                }
            }
            error.stretchHeight = true;
            error.normal.textColor = Color.red;
        }