BMidiConsumer* BMidiRoster::FindConsumer(int32 id, bool localOnly) { BMidiEndpoint* endp = FindEndpoint(id, localOnly); if ((endp != NULL) && !endp->IsConsumer()) { endp->Release(); endp = NULL; } return (BMidiConsumer*) endp; }
BMidiConsumer* BMidiRoster::NextConsumer(int32* id) { BMidiEndpoint* endp; while ((endp = NextEndpoint(id)) != NULL) { if (endp->IsConsumer()) { return (BMidiConsumer*) endp; } endp->Release(); } return NULL; }