Пример #1
0
        public virtual void ShowToolTip()
        {
            foreach (var element in Elements.GetVisibleControls())
            {
                element.ShowToolTip();
            }

            //show tooltip
            if (m_showToolTip && (Enabled || ShowTooltipWhenDisabled))
            {
                if ((MyGuiManager.TotalTimeInMilliseconds > m_showToolTipDelay) && (m_toolTip != null) && (m_toolTip.ToolTips.Count > 0))
                {
                    m_toolTipPosition = MyGuiManager.MouseCursorPosition;
                    m_toolTip.Draw(m_toolTipPosition);
                }
            }
        }
Пример #2
0
        public static MyGuiControlBase GetExclusiveInputHandler(MyGuiControls controls)
        {
            foreach (var control in controls.GetVisibleControls())
            {
                var exclusiveInputHandler = control.GetExclusiveInputHandler();
                if (exclusiveInputHandler != null)
                {
                    return(exclusiveInputHandler);
                }
            }

            return(null);
        }