Developer

API Reference

IWidget_GetLeafWidgetAtCoordinate()

Brew Release
Brew MP 1.0.2
See Also
- IWidget_FindElement()
- IWidget_GetWidgetByID()
Description
This inline function performs the hit-test at the specified coordinate and retrieves the "leaf widget" of the widget tree at that coordinate. On return, this function fills the "leaf widget" of the widget tree and the localized coordinates for the supplied widget. The 'ppiwLeaf' output parameter is ADDRef-ed. Generally, IWidget_FindElement() for a container returns one of the children of that container, which in turn could be a different container. IWidget_GetLeafWidgetAtCoordinate() recursively finds the widget till it gets a non-container, non-decorator widget at the given co-ordinate
Parameters
  • piRoot
    []:
    [in] A pointer to the Parent IWidget interface (of container)
  • px
    []:
    [in/out] Input - x coordinate (hit point) Output - x coordinate relative to supplied widget
  • py
    []:
    [in/out] Input - y coordinate (hit point) Output - y coordinate relative to supplied widget
  • ppiwLeaf
    []:
    [out] Pointer to an IWidget Interface pointer, into which the "Furthest or Lowest" Widget at the provided coordinate is returned
Interface
Prototype
   int IWidget_GetLeafWidgetAtCoordinate(IWidget *piRoot, int *px, int *py, IWidget** ppiwLeaf)
Return
   AEE_SUCCESS - If the requested operation was performed successfully.
   AEE_EFAILED - Root Container itself is a leafwidget.
Side Effect
None
Comment
None
  • Follow