qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Blue Swirl <blauwirbel@gmail.com>
To: qemu-devel@nongnu.org
Subject: [Qemu-devel] [5396] Make keysym tables const
Date: Thu, 02 Oct 2008 18:26:43 +0000	[thread overview]
Message-ID: <E1KlSst-0006Kd-SW@cvs.savannah.gnu.org> (raw)

Revision: 5396
          http://svn.sv.gnu.org/viewvc/?view=rev&root=qemu&revision=5396
Author:   blueswir1
Date:     2008-10-02 18:26:42 +0000 (Thu, 02 Oct 2008)

Log Message:
-----------
Make keysym tables const

Modified Paths:
--------------
    trunk/curses_keys.h
    trunk/keymaps.c
    trunk/sdl_keysym.h
    trunk/vnc_keysym.h

Modified: trunk/curses_keys.h
===================================================================
--- trunk/curses_keys.h	2008-10-02 18:24:21 UTC (rev 5395)
+++ trunk/curses_keys.h	2008-10-02 18:26:42 UTC (rev 5396)
@@ -37,7 +37,7 @@
 
 #define CURSES_KEYS         KEY_MAX     /* KEY_MAX defined in <curses.h> */
 
-static int curses2keycode[CURSES_KEYS] = {
+static const int curses2keycode[CURSES_KEYS] = {
     [0 ... (CURSES_KEYS - 1)] = -1,
 
     [0x01b] = 1, /* Escape */
@@ -216,7 +216,7 @@
 
 };
 
-static int curses2keysym[CURSES_KEYS] = {
+static const int curses2keysym[CURSES_KEYS] = {
     [0 ... (CURSES_KEYS - 1)] = -1,
 
     ['\n'] = '\n',
@@ -244,7 +244,7 @@
 	int keysym;
 } name2keysym_t;
 
-static name2keysym_t name2keysym[] = {
+static const name2keysym_t name2keysym[] = {
     /* Plain ASCII */
     { "space", 0x020 },
     { "exclam", 0x021 },

Modified: trunk/keymaps.c
===================================================================
--- trunk/keymaps.c	2008-10-02 18:24:21 UTC (rev 5395)
+++ trunk/keymaps.c	2008-10-02 18:26:42 UTC (rev 5396)
@@ -24,7 +24,7 @@
 
 static int get_keysym(const char *name)
 {
-    name2keysym_t *p;
+    const name2keysym_t *p;
     for(p = name2keysym; p->name != NULL; p++) {
         if (!strcmp(p->name, name))
             return p->keysym;

Modified: trunk/sdl_keysym.h
===================================================================
--- trunk/sdl_keysym.h	2008-10-02 18:24:21 UTC (rev 5395)
+++ trunk/sdl_keysym.h	2008-10-02 18:26:42 UTC (rev 5396)
@@ -2,7 +2,7 @@
 	const char* name;
 	int keysym;
 } name2keysym_t;
-static name2keysym_t name2keysym[]={
+static const name2keysym_t name2keysym[]={
 /* ascii */
     { "space",                0x020},
     { "exclam",               0x021},

Modified: trunk/vnc_keysym.h
===================================================================
--- trunk/vnc_keysym.h	2008-10-02 18:24:21 UTC (rev 5395)
+++ trunk/vnc_keysym.h	2008-10-02 18:26:42 UTC (rev 5396)
@@ -2,7 +2,7 @@
 	const char* name;
 	int keysym;
 } name2keysym_t;
-static name2keysym_t name2keysym[]={
+static const name2keysym_t name2keysym[]={
 /* ascii */
     { "space",                0x020},
     { "exclam",               0x021},

                 reply	other threads:[~2008-10-02 18:26 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=E1KlSst-0006Kd-SW@cvs.savannah.gnu.org \
    --to=blauwirbel@gmail.com \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).