示例#1
0
        public static IDraw DrawEnumPopup <TEnum>(this IDraw draw,
                                                  ref TEnum @enum,
                                                  string label      = null,
                                                  GUIStyle style    = null,
                                                  float?height      = null,
                                                  float?maxHeight   = null,
                                                  float?minHeight   = null,
                                                  bool?expandHeight = null,
                                                  float?width       = null,
                                                  float?maxWidth    = null,
                                                  float?minWidth    = null,
                                                  bool?expandWidth  = null)
            where TEnum : struct, IConvertible
        {
            var opts = LayoutOptionsCache.ExtractLayoutOptions(height,
                                                               maxHeight,
                                                               minHeight,
                                                               expandHeight,
                                                               width,
                                                               maxWidth,
                                                               minWidth,
                                                               expandWidth);

            EnumPopupDraw.Draw(ref @enum, label, style, opts);

            return(draw);
        }
示例#2
0
        public static IDraw S_DrawEnumPopup <TEnum>(this IDraw draw,
                                                    ref TEnum @enum,
                                                    string label   = null,
                                                    GUIStyle style = null)
            where TEnum : struct, IConvertible
        {
            EnumPopupDraw.Draw(ref @enum, label, style, null);

            return(draw);
        }