SDL_GetTrayEntries(): Rename parameter size to count
This commit is contained in:
committed by
Sam Lantinga
parent
b99e19c0a2
commit
68dabd48c4
@@ -250,7 +250,7 @@ extern SDL_DECLSPEC SDL_TrayMenu * SDLCALL SDL_GetTraySubmenu(SDL_TrayEntry *ent
|
|||||||
* Returns a list of entries in the menu, in order.
|
* Returns a list of entries in the menu, in order.
|
||||||
*
|
*
|
||||||
* \param menu The menu to get entries from.
|
* \param menu The menu to get entries from.
|
||||||
* \param size An optional pointer to obtain the number of entries in the
|
* \param count An optional pointer to obtain the number of entries in the
|
||||||
* menu.
|
* menu.
|
||||||
* \returns a NULL-terminated list of entries within the given menu. The
|
* \returns a NULL-terminated list of entries within the given menu. The
|
||||||
* pointer becomes invalid when any function that inserts or deletes
|
* pointer becomes invalid when any function that inserts or deletes
|
||||||
@@ -264,7 +264,7 @@ extern SDL_DECLSPEC SDL_TrayMenu * SDLCALL SDL_GetTraySubmenu(SDL_TrayEntry *ent
|
|||||||
* \sa SDL_RemoveTrayEntry
|
* \sa SDL_RemoveTrayEntry
|
||||||
* \sa SDL_InsertTrayEntryAt
|
* \sa SDL_InsertTrayEntryAt
|
||||||
*/
|
*/
|
||||||
extern SDL_DECLSPEC const SDL_TrayEntry ** SDLCALL SDL_GetTrayEntries(SDL_TrayMenu *menu, int *size);
|
extern SDL_DECLSPEC const SDL_TrayEntry ** SDLCALL SDL_GetTrayEntries(SDL_TrayMenu *menu, int *count);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Removes a tray entry.
|
* Removes a tray entry.
|
||||||
|
|||||||
@@ -285,15 +285,15 @@ SDL_TrayMenu *SDL_GetTraySubmenu(SDL_TrayEntry *entry)
|
|||||||
return entry->submenu;
|
return entry->submenu;
|
||||||
}
|
}
|
||||||
|
|
||||||
const SDL_TrayEntry **SDL_GetTrayEntries(SDL_TrayMenu *menu, int *size)
|
const SDL_TrayEntry **SDL_GetTrayEntries(SDL_TrayMenu *menu, int *count)
|
||||||
{
|
{
|
||||||
if (!menu) {
|
if (!menu) {
|
||||||
SDL_InvalidParamError("menu");
|
SDL_InvalidParamError("menu");
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (size) {
|
if (count) {
|
||||||
*size = menu->nEntries;
|
*count = menu->nEntries;
|
||||||
}
|
}
|
||||||
return (const SDL_TrayEntry **)menu->entries;
|
return (const SDL_TrayEntry **)menu->entries;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -66,7 +66,7 @@ SDL_TrayMenu *SDL_GetTraySubmenu(SDL_TrayEntry *entry)
|
|||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
const SDL_TrayEntry **SDL_GetTrayEntries(SDL_TrayMenu *menu, int *size)
|
const SDL_TrayEntry **SDL_GetTrayEntries(SDL_TrayMenu *menu, int *count)
|
||||||
{
|
{
|
||||||
SDL_InvalidParamError("menu");
|
SDL_InvalidParamError("menu");
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|||||||
@@ -540,15 +540,15 @@ SDL_TrayMenu *SDL_GetTraySubmenu(SDL_TrayEntry *entry)
|
|||||||
return entry->submenu;
|
return entry->submenu;
|
||||||
}
|
}
|
||||||
|
|
||||||
const SDL_TrayEntry **SDL_GetTrayEntries(SDL_TrayMenu *menu, int *size)
|
const SDL_TrayEntry **SDL_GetTrayEntries(SDL_TrayMenu *menu, int *count)
|
||||||
{
|
{
|
||||||
if (!menu) {
|
if (!menu) {
|
||||||
SDL_InvalidParamError("menu");
|
SDL_InvalidParamError("menu");
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (size) {
|
if (count) {
|
||||||
*size = menu->nEntries;
|
*count = menu->nEntries;
|
||||||
}
|
}
|
||||||
return (const SDL_TrayEntry **)menu->entries;
|
return (const SDL_TrayEntry **)menu->entries;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -367,15 +367,15 @@ SDL_TrayMenu *SDL_GetTraySubmenu(SDL_TrayEntry *entry)
|
|||||||
return entry->submenu;
|
return entry->submenu;
|
||||||
}
|
}
|
||||||
|
|
||||||
const SDL_TrayEntry **SDL_GetTrayEntries(SDL_TrayMenu *menu, int *size)
|
const SDL_TrayEntry **SDL_GetTrayEntries(SDL_TrayMenu *menu, int *count)
|
||||||
{
|
{
|
||||||
if (!menu) {
|
if (!menu) {
|
||||||
SDL_InvalidParamError("menu");
|
SDL_InvalidParamError("menu");
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (size) {
|
if (count) {
|
||||||
*size = menu->nEntries;
|
*count = menu->nEntries;
|
||||||
}
|
}
|
||||||
return (const SDL_TrayEntry **)menu->entries;
|
return (const SDL_TrayEntry **)menu->entries;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user