Пример #1
0
 internal static void Load()
 {
     @namespace      = LanguageIconSet.Load("Namespace");
     @interface      = LanguageIconSet.Load("Interface");
     @class          = LanguageIconSet.Load("Class");
     @struct         = LanguageIconSet.Load("Struct");
     @enum           = LanguageIconSet.Load("Enum");
     primitive       = LanguageIconSet.Load("Primitive");
     field           = LanguageIconSet.Load("Field");
     property        = LanguageIconSet.Load("Property");
     method          = LanguageIconSet.Load("Method");
     extensionMethod = LanguageIconSet.Load("ExtensionMethod");
     constructor     = LanguageIconSet.Load("Constructor");
     @const          = LanguageIconSet.Load("Const");
     favorite        = LanguageIconSet.Load("Favorite");
 }
Пример #2
0
        private static EditorTexture GetTypeVisibilityIcon(Type type, LanguageIconSet languageIcon)
        {
            if (languageIcon == null)
            {
                return(null);
            }

            if (type.IsNested)
            {
                if (type.IsNestedPrivate)
                {
                    return(languageIcon.@private);
                }

                if (type.IsNestedFamily)
                {
                    return(languageIcon.@protected);
                }

                if (type.IsNestedAssembly)
                {
                    return(languageIcon.@internal);
                }

                if (type.IsNestedPublic)
                {
                    return(languageIcon.@public);
                }
            }
            else
            {
                if (type.IsPublic)
                {
                    return(languageIcon.@public);
                }

                return(languageIcon.@internal);
            }

            return(null);
        }