summaryrefslogtreecommitdiffstats
path: root/unix
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2020-03-22 23:01:36 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2020-03-22 23:01:36 (GMT)
commitabbe37191732849b4d22072a8572f29205025457 (patch)
tree4d23c2e469c1e7df8fd7f042acab00c4013c741e /unix
parentaa04c8587cfa2e9a524fae862fae9fdc584ae4c4 (diff)
downloadtk-abbe37191732849b4d22072a8572f29205025457.zip
tk-abbe37191732849b4d22072a8572f29205025457.tar.gz
tk-abbe37191732849b4d22072a8572f29205025457.tar.bz2
Fix [f4dec2c2287aee9e]: Build failure with GCC 4.X (tkUnixKey.c)
Diffstat (limited to 'unix')
-rw-r--r--unix/tkUnixKey.c13
1 files changed, 4 insertions, 9 deletions
diff --git a/unix/tkUnixKey.c b/unix/tkUnixKey.c
index 87aa888..3e41626 100644
--- a/unix/tkUnixKey.c
+++ b/unix/tkUnixKey.c
@@ -306,6 +306,10 @@ TkpSetKeycodeAndState(
*----------------------------------------------------------------------
*/
+#ifdef __GNUC__
+# pragma GCC diagnostic ignored "-Wdeprecated-declarations"
+#endif
+
KeySym
TkpGetKeySym(
TkDisplay *dispPtr, /* Display in which to map keycode. */
@@ -363,11 +367,6 @@ TkpGetKeySym(
index += 1;
}
-#ifdef __GNUC__
-# pragma GCC diagnostic push
-# pragma GCC diagnostic ignored "-Wdeprecated-declarations"
-#endif
-
sym = TkKeycodeToKeysym(dispPtr, eventPtr->xkey.keycode, 0,
index);
@@ -472,10 +471,6 @@ TkpInitKeymapInfo(
}
keysym = TkKeycodeToKeysym(dispPtr, *codePtr, 0, 0);
-#ifdef __GNUC__
-# pragma GCC diagnostic pop
-#endif
-
if (keysym == XK_Mode_switch) {
dispPtr->modeModMask |= ShiftMask << (i/modMapPtr->max_keypermod);
}