From: Amos Kong <akong@redhat.com>
To: Luiz Capitulino <lcapitulino@redhat.com>
Cc: aliguori@us.ibm.com, eblake@redhat.com, qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH v7 5/6] add the QKeyCode enum and the key_defs table
Date: Fri, 31 Aug 2012 10:44:44 +0800 [thread overview]
Message-ID: <5040251C.10901@redhat.com> (raw)
In-Reply-To: <20120830144638.3d68eb0d@doriath.home>
On 31/08/12 01:46, Luiz Capitulino wrote:
> On Mon, 20 Aug 2012 12:39:28 +0800
> Amos Kong<akong@redhat.com> wrote:
>
>> key_defs[] in monitor.c is a mapping table of keys and keycodes,
>> this patch added a QKeyCode enum and a new key_defs table,
>> key's index in the enmu is same as keycode's index in new key_defs[].
>>
>> And added two help functions to convert key/code to index of mapping
>> table, those functions will return Q_KEY_CODE_MAX if the code/key is
>> invalid.
>>
>> 'key_defs' was dropped from the monitor, monitor functions were
>> changed to access key_defs directly.
>>
>> Signed-off-by: Amos Kong<akong@redhat.com>
>
> This patch (and probably the next one too) doesn't apply on master, could
> you rebase please?
Will send V8 later.
> As you'll have to respin, please change versions to 1.3.0. I also have
> comments below (minor, but as you'll respin anyway).
Ok.
>> ---
>> console.h | 6 ++
>> input.c | 186 ++++++++++++++++++++++++++++++++++++++++++++++++++++++
>> monitor.c | 183 +++-------------------------------------------------
>> qapi-schema.json | 26 ++++++++
>> 4 files changed, 229 insertions(+), 172 deletions(-)
>>
>> diff --git a/console.h b/console.h
>> index 4334db5..7934b11 100644
>> --- a/console.h
>> +++ b/console.h
>> @@ -6,6 +6,7 @@
>> #include "notify.h"
>> #include "monitor.h"
>> #include "trace.h"
>> +#include "qapi-types.h"
>>
>> /* keyboard/mouse support */
>>
>> @@ -397,4 +398,9 @@ static inline int vnc_display_pw_expire(DisplayState *ds, time_t expires)
>> /* curses.c */
>> void curses_display_init(DisplayState *ds, int full_screen);
>>
>> +/* input.c */
>> +extern const int key_defs[];
>
> Why are you exporting key_defs[]? It should be static.
key_defs[] is used in do_send_key() after applying this patch, so export
key_defs[].
It will be changed to static in next patch.
> Also, it would be better to move the addition of QKeyCode out of this patch
> (ie. you first add it and then move the table).
Will do it.
--
Amos.
next prev parent reply other threads:[~2012-08-31 2:44 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-08-20 4:39 [Qemu-devel] [PATCH v7 0/6] convert sendkey to qapi Amos Kong
2012-08-20 4:39 ` [Qemu-devel] [PATCH v7 1/6] fix doc of using raw values with sendkey Amos Kong
2012-08-20 4:39 ` [Qemu-devel] [PATCH v7 2/6] monitor: rename keyname '<' to 'less' Amos Kong
2012-08-20 4:39 ` [Qemu-devel] [PATCH v7 3/6] hmp: rename arguments Amos Kong
2012-08-20 4:39 ` [Qemu-devel] [PATCH v7 4/6] qapi: generate list struct and visit_list for enum Amos Kong
2012-08-20 4:39 ` [Qemu-devel] [PATCH v7 5/6] add the QKeyCode enum and the key_defs table Amos Kong
2012-08-30 17:46 ` Luiz Capitulino
2012-08-31 2:44 ` Amos Kong [this message]
2012-08-20 4:39 ` [Qemu-devel] [PATCH v7 6/6] qapi: convert sendkey Amos Kong
2012-08-20 13:25 ` [Qemu-devel] [PATCH v7 0/6] convert sendkey to qapi Eric Blake
2012-08-20 15:08 ` Luiz Capitulino
2012-08-27 7:23 ` Amos Kong
2012-08-27 13:20 ` Luiz Capitulino
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=5040251C.10901@redhat.com \
--to=akong@redhat.com \
--cc=aliguori@us.ibm.com \
--cc=eblake@redhat.com \
--cc=lcapitulino@redhat.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.