private static TranslationKey ApplyTypeToTranslationKey(TranslationKey key, Type type)
        {
            var e = TypeToTranslationKey;

            if (e == null)
            {
                return(key);
            }
            var args = new TypeToTranslationKeyArgs(key, type);

            e(args);
            if (args.Key != null)
            {
                key = args.Key;
            }

            return(key);
        }
        private static TranslationKey ApplyMemberToTranslationKey(TranslationKey key, MemberInfo member)
        {
            var e = MemberToTranslationKey;

            if (e == null)
            {
                return(key);
            }
            var args = new MemberToTranslationKeyArgs(key, member);

            e(args);
            if (args.Key != null)
            {
                key = args.Key;
            }

            return(key);
        }
Ejemplo n.º 3
0
 public StaticFieldLocalTextSource(TranslationKey key, FieldInfo field, bool isLocalizable)
 {
     _field        = field;
     Key           = key;
     IsLocalizable = isLocalizable;
 }
 public MemberToTranslationKeyArgs(TranslationKey originalKey, MemberInfo source)
     : base(originalKey, source)
 {
 }
Ejemplo n.º 5
0
 public TypeToTranslationKeyArgs(TranslationKey originalKey, Type source) : base(originalKey, source)
 {
 }