X-Git-Url: http://ncurses.scripts.mit.edu/?a=blobdiff_plain;f=ncurses%2Fbase%2Flib_mouse.c;h=36b6e1eeace40f4a8a9fabd4ede1da6670937800;hb=6a530b46563470c2ca73579d1994a0c8e275dd98;hp=1b3fa4e51840c42f65a3cf36d0c446ce39b5802b;hpb=6434e809cb70f93cc76d0f833e74447e32c99f54;p=ncurses.git diff --git a/ncurses/base/lib_mouse.c b/ncurses/base/lib_mouse.c index 1b3fa4e5..36b6e1ee 100644 --- a/ncurses/base/lib_mouse.c +++ b/ncurses/base/lib_mouse.c @@ -1,5 +1,5 @@ /**************************************************************************** - * Copyright (c) 1998-2013,2014 Free Software Foundation, Inc. * + * Copyright (c) 1998-2014,2015 Free Software Foundation, Inc. * * * * Permission is hereby granted, free of charge, to any person obtaining a * * copy of this software and associated documentation files (the * @@ -84,7 +84,7 @@ #define CUR SP_TERMTYPE #endif -MODULE_ID("$Id: lib_mouse.c,v 1.163 2014/10/18 10:32:02 tom Exp $") +MODULE_ID("$Id: lib_mouse.c,v 1.166 2015/07/05 00:28:27 tom Exp $") #include @@ -432,7 +432,7 @@ enable_xterm_mouse(SCREEN *sp, int enable) #if USE_GPM_SUPPORT static bool -allow_gpm_mouse(SCREEN *sp) +allow_gpm_mouse(SCREEN *sp GCC_UNUSED) { bool result = FALSE; @@ -446,8 +446,8 @@ allow_gpm_mouse(SCREEN *sp) #endif /* GPM does printf's without checking if stdout is a terminal */ if (NC_ISATTY(fileno(stdout))) { - char *list = getenv("NCURSES_GPM_TERMS"); - char *env = getenv("TERM"); + const char *list = getenv("NCURSES_GPM_TERMS"); + const char *env = getenv("TERM"); if (list != 0) { if (env != 0) { result = _nc_name_match(list, env, "|:"); @@ -608,7 +608,7 @@ initialize_mousetype(SCREEN *sp) int rc; if (!sp->_emxmouse_buttons[0]) { - char *s = getenv("MOUSE_BUTTONS_123"); + const char *s = getenv("MOUSE_BUTTONS_123"); sp->_emxmouse_buttons[0] = 1; if (s && strlen(s) >= 3) { @@ -1248,7 +1248,6 @@ decode_xterm_SGR1006(SCREEN *sp, MEVENT * eventp) int b = data.params[0]; int b3 = 1 + (b & 3); - result = TRUE; eventp->id = NORMAL_EVENT; if (data.final == 'M') { (void) handle_wheel(sp, eventp, b, (b & 64) == 64);