diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/gos/linux.h | 1 | ||||
-rw-r--r-- | include/gwin/list.h | 9 |
2 files changed, 8 insertions, 2 deletions
diff --git a/include/gos/linux.h b/include/gos/linux.h index 7529a962..508b2b68 100644 --- a/include/gos/linux.h +++ b/include/gos/linux.h @@ -16,6 +16,7 @@ #if GFX_USE_OS_LINUX #include <sys/types.h> +#include <stdlib.h> #include <stdint.h> #include <pthread.h> diff --git a/include/gwin/list.h b/include/gwin/list.h index 0b525b03..46e32d5c 100644 --- a/include/gwin/list.h +++ b/include/gwin/list.h @@ -37,13 +37,16 @@ * @brief A list event */ typedef struct GEventGWinList { - GEventType type; // The type of this event (GEVENT_GWIN_LIST) - GHandle list; // THe list that has generated the event + GEventType type; // The type of this event (GEVENT_GWIN_LIST) + GHandle list; // The list + int item; // The item that has been selected (or unselected in a multi-select listbox) } GEventGWinList; // A list window typedef struct GListObject { GWidgetObject w; + int cnt; // Number of items currently in the list (quicker than counting each time) + gfxQueueASync list_head; // The list of items } GListObject; #ifdef __cplusplus @@ -52,6 +55,8 @@ extern "C" { GHandle gwinListCreate(GListObject *widget, GWidgetInit *pInit); +int gwinListAddItem(GHandle gh, const char* item, bool_t useAlloc); + #ifdef __cplusplus } #endif |