2 CLASS(NexuizListBox) EXTENDS(ListBox)
3 METHOD(NexuizListBox, configureNexuizListBox, void(entity))
4 ATTRIB(NexuizListBox, fontSize, float, SKINFONTSIZE_NORMAL)
5 ATTRIB(NexuizListBox, scrollbarWidth, float, SKINWIDTH_SCROLLBAR)
6 ATTRIB(NexuizListBox, src, string, SKINGFX_SCROLLBAR)
7 ATTRIB(NexuizListBox, tolerance, vector, SKINTOLERANCE_SLIDER)
8 ATTRIB(NexuizListBox, rowsPerItem, float, 1)
9 METHOD(NexuizListBox, resizeNotify, void(entity, vector, vector, vector, vector))
10 ATTRIB(NexuizListBox, color, vector, SKINCOLOR_SCROLLBAR_N)
11 ATTRIB(NexuizListBox, colorF, vector, SKINCOLOR_SCROLLBAR_F)
12 ATTRIB(NexuizListBox, color2, vector, SKINCOLOR_SCROLLBAR_S)
13 ENDCLASS(NexuizListBox)
14 entity makeNexuizListBox();
18 entity makeNexuizListBox()
21 me = spawnNexuizListBox();
22 me.configureNexuizListBox(me);
25 void configureNexuizListBoxNexuizListBox(entity me)
27 me.configureListBox(me, me.scrollbarWidth, 1); // item height gets set up later
29 void resizeNotifyNexuizListBox(entity me, vector relOrigin, vector relSize, vector absOrigin, vector absSize)
31 me.itemHeight = me.rowsPerItem * me.fontSize / absSize_y;
32 resizeNotifyListBox(me, relOrigin, relSize, absOrigin, absSize);