About Store Forum Documentation Contact
Donations:
140$/mo



Post Reply 
[Solved] Make a filter in Gui List
Author Message
Avatar Offline
Member

Post: #1
[Solved] Make a filter in Gui List
Hi,

i have an GUI list :

Definition Section :

Code:
struct MyStruct     // Definition of Struct
{
  int type;
  str name;
}
Memc<MyStruct> MyMemc;  // Definition of Memory address

ListGroup MyListGroup[]=     // Definition of the ListGroup
{
   ListGroup(MEMBER(MyStruct,type)        ,0.05f    ,L"type" ),
   ListGroup(MEMBER(MyStruct,name)      ,0.75f    ,L"name" ),
};

List<MyStruct> MyList;          // Definition of the List

In the init Section :

Code:
gui_Region = gui.findRegion("R_Type");
*gui_Region  += MyList.create( MyListGroup , Elms(MyListGroup) );
MyList.setData(MyMemc);

I have create a Buttom to filter the gui list screen by type =1;
I have search but i dont found solution to create a filter on a Gui list.

It is possible, and if yes, how to ?

Thanks for your help.
Avatar
(This post was last modified: 07-20-2011 04:02 AM by Avatar.)
07-19-2011 07:57 PM
Find all posts by this user Quote this message in a reply
Avatar Offline
Member

Post: #2
RE: Make a filter in Gui List
Ok i found a way, i use another Memc and i rebuild this Memc for each filter.

Avatar
07-20-2011 04:02 AM
Find all posts by this user Quote this message in a reply
Esenthel Offline
Administrator

Post: #3
RE: [Solved] Make a filter in Gui List
in setData there you can pass Bool visible array for each element
07-21-2011 12:45 PM
Find all posts by this user Quote this message in a reply
Avatar Offline
Member

Post: #4
RE: [Solved] Make a filter in Gui List
Thx, i will test that as soon as possible.

Avatar
07-22-2011 07:22 PM
Find all posts by this user Quote this message in a reply
Post Reply