MonoDroidToolkit.ResourceIdManager.UpdateIdValues C# (CSharp) Method

UpdateIdValues() public static method

public static UpdateIdValues ( ) : void
return void
        public static void UpdateIdValues()
        {
            if (_idInitialized)
                return;
            var eass = Assembly.GetExecutingAssembly ();
            Func<Assembly,Type> f = ass =>
                ass.GetCustomAttributes (typeof (ResourceDesignerAttribute), true)
                    .Select (ca => ca as ResourceDesignerAttribute)
                    .Where (ca => ca != null && ca.IsApplication)
                    .Select (ca => ass.GetType (ca.FullName))
                    .Where (ty => ty != null)
                    .FirstOrDefault ();
            var t = f (eass);
            if (t == null)
                t = AppDomain.CurrentDomain.GetAssemblies ().Select (ass => f (ass)).Where (ty => ty != null).FirstOrDefault ();
            if (t != null)
                t.GetMethod ("UpdateIdValues").Invoke (null, new object [0]);
            _idInitialized = true;
        }

Usage Example

Ejemplo n.º 1
0
 public ScrollingTextView(Context context, IAttributeSet attrs)
     : base(context, attrs)
 {
     ResourceIdManager.UpdateIdValues();
 }
All Usage Examples Of MonoDroidToolkit.ResourceIdManager::UpdateIdValues
ResourceIdManager