mirror of
https://github.com/gryf/wmaker.git
synced 2026-02-10 10:35:46 +01:00
WINGs: fix duplicate if/else branch in W_LookupString
cppcheck is reporting the msg below: [../WINGs/winputmethod.c:215] -> [../WINGs/winputmethod.c:209]: (style) Found duplicate branches for 'if' and 'else'. The patch is fixing it by setting a default return call.
This commit is contained in:
committed by
Carlos R. Mafra
parent
5088b6755d
commit
db9f5c9658
@@ -199,20 +199,15 @@ void W_SetPreeditPositon(W_View * view, int x, int y)
|
||||
}
|
||||
}
|
||||
|
||||
int
|
||||
W_LookupString(W_View * view, XKeyPressedEvent * event, char *buffer, int buflen, KeySym * keysym, Status * status)
|
||||
int W_LookupString(W_View *view, XKeyPressedEvent *event, char *buffer, int buflen, KeySym *keysym, Status *status)
|
||||
{
|
||||
WMScreen *scr = W_VIEW_SCREEN(view);
|
||||
|
||||
XSetInputFocus(scr->display, view->window, RevertToParent, CurrentTime);
|
||||
|
||||
if (view->xic) {
|
||||
#ifdef X_HAVE_UTF8_STRING
|
||||
if (view->xic)
|
||||
return Xutf8LookupString(view->xic, event, buffer, buflen, keysym, status);
|
||||
#else
|
||||
return XLookupString(event, buffer, buflen, keysym, (XComposeStatus *) status);
|
||||
#endif
|
||||
} else {
|
||||
return XLookupString(event, buffer, buflen, keysym, (XComposeStatus *) status);
|
||||
}
|
||||
return XLookupString(event, buffer, buflen, keysym, (XComposeStatus *) status);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user