From 210ef6a7c0b8e10edc80be73470dc5368f06e20e Mon Sep 17 00:00:00 2001 From: Niklas Mischkulnig Date: Fri, 4 May 2018 11:53:07 +0200 Subject: [PATCH] Area events parameter type fix --- src/UiArea/UiAreaHandler.cc | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/src/UiArea/UiAreaHandler.cc b/src/UiArea/UiAreaHandler.cc index 2287601..d3d745b 100644 --- a/src/UiArea/UiAreaHandler.cc +++ b/src/UiArea/UiAreaHandler.cc @@ -3,25 +3,26 @@ void Draw(UiAreaHandler *self, uiArea *area, uiAreaDrawParams *params) { UiAreaDrawParams *pp = new UiAreaDrawParams(params); - (*self->draw)(controlsMap[uiControl(area)], pp); + (*self->draw)((UiArea *)controlsMap[uiControl(area)], pp); } void MouseEvent(UiAreaHandler *self, uiArea *area, uiAreaMouseEvent *event) { UiAreaMouseEvent *ev = new UiAreaMouseEvent(event); - (*(self->mouseEvent))(controlsMap[uiControl(area)], ev); + (*(self->mouseEvent))((UiArea *)controlsMap[uiControl(area)], ev); } void MouseCrossed(UiAreaHandler *self, uiArea *area, int left) { - (*(self->mouseCrossed))(controlsMap[uiControl(area)], left); + (*(self->mouseCrossed))((UiArea *)controlsMap[uiControl(area)], left); } void DragBroken(UiAreaHandler *self, uiArea *area) { - (*(self->dragBroken))(controlsMap[uiControl(area)]); + (*(self->dragBroken))((UiArea *)controlsMap[uiControl(area)]); } int KeyEvent(UiAreaHandler *self, uiArea *area, uiAreaKeyEvent *event) { UiAreaKeyEvent *ev = new UiAreaKeyEvent(event); - return (self->keyEvent)->call(controlsMap[uiControl(area)], ev); + return (self->keyEvent) + ->call((UiArea *)controlsMap[uiControl(area)], ev); } UiAreaHandler *UiAreaHandlerFactory::build(nbind::cbFunction &drawCb,