예제 #1
0
        protected override object GetUIElementAtPoint(object parent, System.Drawing.Point pt)
        {
            // try to find a child UI element by its coordinates inside the parent
            object child = C1RibbonHelper.GetChildAtPoint(parent, pt);

            // if a child UI element at the specified point was found, return it
            if (child != null)
            {
                return(child);
            }

            // child UI element was not found inside the parent
            return(base.GetUIElementAtPoint(parent, pt));
        }
예제 #2
0
        protected override object FindUIElement(object parent, string name)
        {
            // try to find a child UI element by its name inside the parent
            object child = C1RibbonHelper.FindUIElement(parent, name);

            // if a child UI element with the specified name was found, return it
            if (child != null)
            {
                return(child);
            }

            // child UI element was not found inside the parent
            return(base.FindUIElement(parent, name));
        }
예제 #3
0
        protected override C1.Win.C1DynamicHelp.UIElementInfo GetUIElementInfo(object uiElement)
        {
            // Try to get Parent and Name for the specified uiElement.
            // These properties should be stored in UIElementInfo object
            UIElementInfo info = C1RibbonHelper.ResolveControl(uiElement);

            // if we were able to get the uiElement's parent and name, return them in a UIElementInfo object.
            if (info != null)
            {
                return(info);
            }

            // uiElement wasn't handled here, so it should be processed by the C1DynamicHelp control automatically
            return(base.GetUIElementInfo(uiElement));
        }