]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/menu/xonotic/listbox.qc
Merge branch 'master' into Mario/headshots
[xonotic/xonotic-data.pk3dir.git] / qcsrc / menu / xonotic / listbox.qc
index c4a0923858afa4ff668826089e038f0391779055..aa8487c8bf0c50db25a2c1e45e2dfb976e3a1d9f 100644 (file)
@@ -1,25 +1,5 @@
-#ifndef LISTBOX_H
-#define LISTBOX_H
-#include "../item/listbox.qc"
-CLASS(XonoticListBox, ListBox)
-       METHOD(XonoticListBox, configureXonoticListBox, void(entity))
-       ATTRIB(XonoticListBox, fontSize, float, SKINFONTSIZE_NORMAL)
-       ATTRIB(XonoticListBox, scrollbarWidth, float, SKINWIDTH_SCROLLBAR)
-       ATTRIB(XonoticListBox, src, string, SKINGFX_SCROLLBAR)
-       ATTRIB(XonoticListBox, tolerance, vector, SKINTOLERANCE_SLIDER)
-       ATTRIB(XonoticListBox, rowsPerItem, float, 1)
-       METHOD(XonoticListBox, resizeNotify, void(entity, vector, vector, vector, vector))
-       ATTRIB(XonoticListBox, color, vector, SKINCOLOR_SCROLLBAR_N)
-       ATTRIB(XonoticListBox, colorF, vector, SKINCOLOR_SCROLLBAR_F)
-       ATTRIB(XonoticListBox, color2, vector, SKINCOLOR_SCROLLBAR_S)
-       ATTRIB(XonoticListBox, colorC, vector, SKINCOLOR_SCROLLBAR_C)
-       ATTRIB(XonoticListBox, colorBG, vector, SKINCOLOR_LISTBOX_BACKGROUND)
-       ATTRIB(XonoticListBox, alphaBG, float, SKINALPHA_LISTBOX_BACKGROUND)
-ENDCLASS(XonoticListBox)
-entity makeXonoticListBox();
-#endif
+#include "listbox.qh"
 
-#ifdef IMPLEMENTATION
 entity makeXonoticListBox()
 {
        entity me;
@@ -36,4 +16,3 @@ void XonoticListBox_resizeNotify(entity me, vector relOrigin, vector relSize, ve
        me.itemHeight = me.rowsPerItem * me.fontSize / absSize.y;
        SUPER(XonoticListBox).resizeNotify(me, relOrigin, relSize, absOrigin, absSize);
 }
-#endif