Ignore:
Timestamp:
Jan 7, 2011, 2:25:21 PM (11 years ago)
Author:
Sven Rech
Message:

Prepared KeySearcher for Localization

File:
1 copied

Legend:

Unmodified
Added
Removed
  • trunk/CrypPluginBase/Miscellaneous/LocExtension.cs

    r2294 r2295  
    3333    [MarkupExtensionReturnType(typeof(object))]
    3434    [ContentProperty("Key")]
    35     public class SLocExtension : MarkupExtension
     35    public class LocExtension : MarkupExtension
    3636    {
    3737        public string Key { get; set; }
    3838
    39         public SLocExtension(String key)
     39        public LocExtension(String key)
    4040        {
    4141            Key = key;
     
    4747            {
    4848                IRootObjectProvider service = serviceProvider.GetService(typeof(IRootObjectProvider)) as IRootObjectProvider;
    49                 var tabAttribute = (SettingsTabAttribute)Attribute.GetCustomAttribute(service.RootObject.GetType(), typeof(SettingsTabAttribute));
    50                 ResourceManager resman = new ResourceManager(tabAttribute.ResourceFile, service.RootObject.GetType().Assembly);
     49                var locAttribute = (LocalizationAttribute)Attribute.GetCustomAttribute(service.RootObject.GetType(), typeof(LocalizationAttribute));
     50                ResourceManager resman = new ResourceManager(locAttribute.ResourceFile, service.RootObject.GetType().Assembly);
    5151                return resman.GetString(Key);
    5252            }
Note: See TracChangeset for help on using the changeset viewer.