示例#1
0
        public static GUIContent Take(string text = null, string tooltip = null, Texture2D thumbnail = null)
        {
            GUIContent content = s_GUIContentPool[s_GUIContentPoolIndex];

            if (content == null)
            {
                s_GUIContentPool[s_GUIContentPoolIndex] = content = new GUIContent(text, thumbnail, tooltip);
            }
            else
            {
                content.text    = text;
                content.tooltip = tooltip;
                content.image   = thumbnail;
            }

            SearchService.Wrap(s_GUIContentPoolIndex + 1, s_GUIContentPool.Length);
            return(content);
        }
 internal void RecordFetchTime(double t)
 {
     fetchTimes[fetchTimeWriteIndex] = t;
     fetchTimeWriteIndex             = SearchService.Wrap(fetchTimeWriteIndex + 1, fetchTimes.Length);
 }