mGUI: Fix warnings on 64-bit
Vicki Pfau vi@endrift.com
Thu, 20 Sep 2018 11:24:33 -0700
1 files changed,
5 insertions(+),
5 deletions(-)
jump to
M
src/feature/gui/remap.c
→
src/feature/gui/remap.c
@@ -69,13 +69,13 @@ }
if (item->data == (void*) (GUI_INPUT_MAX + map->info->nKeys + 2)) { for (i = 0; i < GUIMenuItemListSize(&menu.items); ++i) { item = GUIMenuItemListGetPointer(&menu.items, i); - if ((uint32_t) item->data < 1) { + if ((uintptr_t) item->data < 1) { continue; } - if ((uint32_t) item->data < GUI_INPUT_MAX + 1) { - mInputBindKey(¶ms->keyMap, keys->id, item->state - 1, (uint32_t) item->data - 1); - } else if ((uint32_t) item->data < GUI_INPUT_MAX + map->info->nKeys + 1) { - mInputBindKey(map, keys->id, item->state - 1, (uint32_t) item->data - GUI_INPUT_MAX - 1); + if ((uintptr_t) item->data < GUI_INPUT_MAX + 1) { + mInputBindKey(¶ms->keyMap, keys->id, item->state - 1, (uintptr_t) item->data - 1); + } else if ((uintptr_t) item->data < GUI_INPUT_MAX + map->info->nKeys + 1) { + mInputBindKey(map, keys->id, item->state - 1, (uintptr_t) item->data - GUI_INPUT_MAX - 1); } } break;