Improve documentation.

This commit is contained in:
Jari Vetoniemi 2014-04-10 20:19:15 +03:00
parent 1f51a67589
commit 05212f5e44
2 changed files with 10 additions and 2 deletions

View File

@ -239,6 +239,8 @@ int bmMenuSetHighlighted(bmMenu *menu, bmItem *item);
/** /**
* Get highlighted item from bmMenu instance. * Get highlighted item from bmMenu instance.
* *
* @warning The pointer returned by this function may be invalid after items change.
*
* @param menu bmMenu instance from where to get highlighted item. * @param menu bmMenu instance from where to get highlighted item.
* @return Selected bmItem instance, **NULL** if none highlighted. * @return Selected bmItem instance, **NULL** if none highlighted.
*/ */
@ -247,7 +249,7 @@ bmItem* bmMenuGetHighlightedItem(const bmMenu *menu);
/** /**
* Set selected items to bmMenu instance. * Set selected items to bmMenu instance.
* *
* @warning The list won't be copied. * @warning The list won't be copied, do not free it.
* *
* @param menu bmMenu instance where items will be set. * @param menu bmMenu instance where items will be set.
* @param items Array of bmItem pointers to set. * @param items Array of bmItem pointers to set.
@ -259,6 +261,8 @@ int bmMenuSetSelectedItems(bmMenu *menu, bmItem **items, unsigned int nmemb);
/** /**
* Get selected items from bmMenu instance. * Get selected items from bmMenu instance.
* *
* @warning The pointer returned by this function may be invalid after selection or items change.
*
* @param menu bmMenu instance from where to get selected items. * @param menu bmMenu instance from where to get selected items.
* @param outNmemb Reference to unsigned int where total count of returned items will be stored. * @param outNmemb Reference to unsigned int where total count of returned items will be stored.
* @return Pointer to array of bmItem pointers. * @return Pointer to array of bmItem pointers.

View File

@ -307,6 +307,8 @@ int bmMenuSetHighlighted(bmMenu *menu, bmItem *item)
/** /**
* Get highlighted item from bmMenu instance. * Get highlighted item from bmMenu instance.
* *
* @warning The pointer returned by this function may be invalid after items change.
*
* @param menu bmMenu instance from where to get highlighted item. * @param menu bmMenu instance from where to get highlighted item.
* @return Selected bmItem instance, **NULL** if none highlighted. * @return Selected bmItem instance, **NULL** if none highlighted.
*/ */
@ -326,7 +328,7 @@ bmItem* bmMenuGetHighlightedItem(const bmMenu *menu)
/** /**
* Set selected items to bmMenu instance. * Set selected items to bmMenu instance.
* *
* @warning The list won't be copied. * @warning The list won't be copied, do not free it.
* *
* @param menu bmMenu instance where items will be set. * @param menu bmMenu instance where items will be set.
* @param items Array of bmItem pointers to set. * @param items Array of bmItem pointers to set.
@ -342,6 +344,8 @@ int bmMenuSetSelectedItems(bmMenu *menu, bmItem **items, unsigned int nmemb)
/** /**
* Get selected items from bmMenu instance. * Get selected items from bmMenu instance.
* *
* @warning The pointer returned by this function may be invalid after selection or items change.
*
* @param menu bmMenu instance from where to get selected items. * @param menu bmMenu instance from where to get selected items.
* @param outNmemb Reference to unsigned int where total count of returned items will be stored. * @param outNmemb Reference to unsigned int where total count of returned items will be stored.
* @return Pointer to array of bmItem pointers. * @return Pointer to array of bmItem pointers.