Listbox problem

If you are a new Irrlicht Engine user, and have a newbie-question, this is the forum for you. You may also post general programming questions here.
Post Reply
Cleves
Posts: 224
Joined: Mon Sep 08, 2003 6:40 pm

Listbox problem

Post by Cleves »

Hey,

I've got a question about listbox.I would like to attach it to a tab in a window, but when I write the name of the window as a parent the listbox dosen't seem to appear.

Here's my code:

Code: Select all


IGUIWindow* options = guienv->addWindow(
						rect<s32>(400,200,800,600), 
						false, // modal
						L"Options");
				 options->getCloseButton()->setVisible(false);
				 
				 // create tab control and tabs
	                 IGUITabControl* optionstab = guienv->addTabControl(
	                	rect<s32>(2,20,800,600),options, true, true); 
	                   
					 IGUITab* video = optionstab->addTab(L"Video");
	                 IGUITab* audio = optionstab->addTab(L"Audio");

					 IGUIListBox* resbox = guienv->addListBox(rect<s32>(420,270,520,320),video); 
					 resbox->addItem(L"640x480");
					 resbox->addItem(L"800x600");
					 resbox->addItem(L"1024x768");
Any Ideas?
Alex
Posts: 8
Joined: Fri Jul 02, 2004 5:27 am
Location: Western Australia
Contact:

Post by Alex »

What do you need to do this for? I can't see why a listbox should be the parent of a tab, unless you want to change tab's based on a listbox selection.
Cleves
Posts: 224
Joined: Mon Sep 08, 2003 6:40 pm

Post by Cleves »

mmm maybe I didn't put it right.I want to put te listbox on the tab, so the listbox would be the child of the tab. Is there any other way I can attach them?
saigumi
Posts: 921
Joined: Fri Aug 22, 2003 11:31 am
Location: St. Louis, MO USA
Contact:

Post by saigumi »

Your problem is most likely related to this bug I reported when 0.6 came out.

All of my GUI elements are children of a tab.

http://irrlicht.sourceforge.net/phpBB2/ ... php?t=1722
Crud, how do I do this again?
Post Reply