been trying to sort this out for a while and if i had hair to loose yup its gone
so i did work in v7 of cegui and porting it over to v8 ran into a prob what i'am trying to do is fill a listbox from a .ini file
if i step though the code i get the description form the ini file just fine but nothing appears in the item listbox and i mean nothing nada cilch
used to be ok with .getWindow old way i know so i'm pretty sure it has to with the tlist part but unsure what it is
"LIST" is the itemlistbox name in the book.layout file
anyways here the code any help kindly recived
Code: Select all
CEGUI::WindowManager& winMgr = CEGUI::WindowManager::getSingleton();
CEGUI::FrameWindow* pb = static_cast<CEGUI::FrameWindow*>( winMgr.loadLayoutFromFile( "book.layout" ) );
entry= Book->GetCurrentPtr();
while ( entry )
{
CEGUI::ItemListbox* tlist = static_cast<CEGUI::ItemListbox*>(winMgr.createWindow("TaharezLook/ItemListbox", "LIST" ));
pb->getChild("LIST");
// create new list item
CEGUI::ItemEntry* pitem = static_cast<CEGUI::ItemEntry*>(winMgr.createWindow("TaharezLook/ListboxItem"));
tlist->addItem(pitem);
// set text on this item to whatever name's are in the ini file
pitem->setText( entry->description );
pitem->setSelected( true );
tlist->invalidate();
tlist->show();
}