Ejemplo n.º 1
0
        //---------------------------------------------------------------------------------------
        public DockStyle HitTestResult(out GUI.ControlContainerInterface _in)
        {
            _in = _Container;
            if (_in == null)
            {
                return(DockStyle.None);
            }

            if (_PictureCenter.Visible)
            {
                return(DockStyle.Fill);
            }
            if (_PictureLeft.Visible)
            {
                return(DockStyle.Left);
            }
            if (_PictureRight.Visible)
            {
                return(DockStyle.Right);
            }
            if (_PictureTop.Visible)
            {
                return(DockStyle.Top);
            }
            if (_PictureBottom.Visible)
            {
                return(DockStyle.Bottom);
            }
            return(DockStyle.None);
        }
Ejemplo n.º 2
0
 //-------------------------------------------------------------------
 public static ITaxonControl FindTaxonControl(Type type, GUI.ControlContainerInterface _container = null)
 {
     foreach (ITaxonControl itc in _List)
     {
         if (itc.GetType() == type)
         {
             if (_container == null || itc.OwnerContainer == _container)
             {
                 return(itc);
             }
         }
     }
     return(null);
 }
Ejemplo n.º 3
0
 //-------------------------------------------------------------------
 public static T FindTaxonControl <T>(GUI.ControlContainerInterface _container = null) where T : class
 {
     foreach (ITaxonControl itc in _List)
     {
         if (itc.GetType() == typeof(T))
         {
             if (_container == null || itc.OwnerContainer == _container)
             {
                 return(itc as T);
             }
         }
     }
     return(null);
 }