On 18/04/2013 at 02:21, xxxxxxxx wrote:
I actually would have thought of something else if I wouldn't have asked for clarification. 
So, I didn't need to interact with the Content Browser, yet. But there's the lib_browser.h header file
(see the SDK documentation) which seems to exactly allow you that kind of interaction. Whether you
can load your own *.lib4d or only libraries already loaded in the Content Browser.. I don't know. It'd
be great if you could show an example when you reached the expected result.
As for the drop-down list: You can open an interface like the right-click context-menu using the
ShowPopupMenu() function. It expects a BaseContainer as input that is used to display the items
in the menu.
BaseContainer bc;
void* handle = SDKBrowserInitBrowsing();
BaseContainer data;
LONG i = 1000;
while (SDKBrowserGetNext(handle, data)) {
bc.SetString(i, data.GetString(SDK_BROWSER_ITEM_NAME));
i += 1;
}
SDKBrowserFreeBrowsing(handle);
LONG selected_item = ShowPopupMenu(NULL, MOUSEPOS, MOUSEPOS, bc);
LONG item_index = selected_item - 1000;
// ...
Note : This is just some untested code that should give you a hint for a possible way to solve this.
The functions SDKBrowserInitBrowsing(), SDKBrowserFreeBrowsing() and SDKBrowserGetNext() and the
constant SDK_BROWSER_ITEM_NAME are invented and the way of iteration over items in the browser
**is ** assumed since I do not have time to go more deeply into the lib_browser library.
Best,
-Niklas