libs/libnx/nxmu/nx_eventhandler.c: Appease nxstyle

This commit is contained in:
YAMAMOTO Takashi 2020-11-20 20:52:59 +09:00 committed by Xiang Xiao
parent 6d8ccccbb0
commit efe8e24fe7
1 changed files with 21 additions and 11 deletions

View File

@ -144,8 +144,9 @@ int nx_eventhandler(NXHANDLE handle)
{
if (errcode == EAGAIN)
{
/* EAGAIN is not an error. It occurs because the MQ is opened with
* O_NONBLOCK and there is no message available now.
/* EAGAIN is not an error. It occurs because the MQ is
* opened with O_NONBLOCK and there is no message
* available now.
*/
return OK;
@ -180,24 +181,28 @@ int nx_eventhandler(NXHANDLE handle)
case NX_CLIMSG_REDRAW:
{
FAR struct nxclimsg_redraw_s *redraw = (FAR struct nxclimsg_redraw_s *)buffer;
FAR struct nxclimsg_redraw_s *redraw =
(FAR struct nxclimsg_redraw_s *)buffer;
wnd = redraw->wnd;
DEBUGASSERT(wnd);
if (wnd->cb->redraw)
{
wnd->cb->redraw((NXWINDOW)wnd, &redraw->rect, redraw->more, wnd->arg);
wnd->cb->redraw((NXWINDOW)wnd, &redraw->rect, redraw->more,
wnd->arg);
}
}
break;
case NX_CLIMSG_NEWPOSITION:
{
FAR struct nxclimsg_newposition_s *postn = (FAR struct nxclimsg_newposition_s *)buffer;
FAR struct nxclimsg_newposition_s *postn =
(FAR struct nxclimsg_newposition_s *)buffer;
wnd = postn->wnd;
DEBUGASSERT(wnd);
if (wnd->cb->position)
{
wnd->cb->position((NXWINDOW)wnd, &postn->size, &postn->pos, &postn->bounds, wnd->arg);
wnd->cb->position((NXWINDOW)wnd, &postn->size, &postn->pos,
&postn->bounds, wnd->arg);
}
}
break;
@ -205,12 +210,14 @@ int nx_eventhandler(NXHANDLE handle)
#ifdef CONFIG_NX_XYINPUT
case NX_CLIMSG_MOUSEIN:
{
FAR struct nxclimsg_mousein_s *mouse = (FAR struct nxclimsg_mousein_s *)buffer;
FAR struct nxclimsg_mousein_s *mouse =
(FAR struct nxclimsg_mousein_s *)buffer;
wnd = mouse->wnd;
DEBUGASSERT(wnd);
if (wnd->cb->mousein)
{
wnd->cb->mousein((NXWINDOW)wnd, &mouse->pos, mouse->buttons, wnd->arg);
wnd->cb->mousein((NXWINDOW)wnd, &mouse->pos, mouse->buttons,
wnd->arg);
}
}
break;
@ -219,7 +226,8 @@ int nx_eventhandler(NXHANDLE handle)
#ifdef CONFIG_NX_KBD
case NX_CLIMSG_KBDIN:
{
FAR struct nxclimsg_kbdin_s *kbd = (FAR struct nxclimsg_kbdin_s *)buffer;
FAR struct nxclimsg_kbdin_s *kbd =
(FAR struct nxclimsg_kbdin_s *)buffer;
wnd = kbd->wnd;
DEBUGASSERT(wnd);
if (wnd->cb->kbdin)
@ -232,12 +240,14 @@ int nx_eventhandler(NXHANDLE handle)
case NX_CLIMSG_EVENT:
{
FAR struct nxclimsg_event_s *event = (FAR struct nxclimsg_event_s *)buffer;
FAR struct nxclimsg_event_s *event =
(FAR struct nxclimsg_event_s *)buffer;
wnd = event->wnd;
DEBUGASSERT(wnd);
if (wnd->cb->event)
{
wnd->cb->event((NXWINDOW)wnd, event->event, wnd->arg, event->arg);
wnd->cb->event((NXWINDOW)wnd, event->event, wnd->arg,
event->arg);
}
}
break;