From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:53732) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SbamF-0001hN-Ei for qemu-devel@nongnu.org; Mon, 04 Jun 2012 13:09:12 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SbamD-0005pv-Iz for qemu-devel@nongnu.org; Mon, 04 Jun 2012 13:09:11 -0400 Received: from mx1.redhat.com ([209.132.183.28]:34658) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SbamD-0005pe-AJ for qemu-devel@nongnu.org; Mon, 04 Jun 2012 13:09:09 -0400 Message-ID: <4FCCEBB1.3040507@redhat.com> Date: Mon, 04 Jun 2012 11:09:05 -0600 From: Eric Blake MIME-Version: 1.0 References: <1338591268-23962-1-git-send-email-akong@redhat.com> <1338591268-23962-7-git-send-email-akong@redhat.com> In-Reply-To: <1338591268-23962-7-git-send-email-akong@redhat.com> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="------------enig0E82D45868DD727E75814C20" Subject: Re: [Qemu-devel] [PATCH v2 6/6] qapi: convert sendkey List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Amos Kong Cc: aliguori@us.ibm.com, qemu-devel@nongnu.org, lcapitulino@redhat.com This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enig0E82D45868DD727E75814C20 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On 06/01/2012 04:54 PM, Amos Kong wrote: > Convert 'sendkey' to use QAPI. do_sendkey() depends on some > variables/functions in monitor.c, so reserve qmp_sendkey() > to monitor.c >=20 > key_defs[] in monitor.c is the mapping of key name to keycode, > Keys' order in the enmu and key_defs[] is same. >=20 > Signed-off-by: Amos Kong > --- > +++ b/qapi-schema.json > @@ -1755,3 +1755,50 @@ > # Since: 0.14.0 > ## > { 'command': 'device_del', 'data': {'id': 'str'} } > + > +## > +# @KeyCodes: > +# > +# An enumeration of key name. > +# > +# This is used by the sendkey command. > +# > +# Since: 0.14.0 Really? Or is this enum since 1.2? > + > +## > +# @sendkey: > +# > +# Send keys to VM. > +# > +# @keys: key sequence > +# @hold-time: time to delay key up events, milliseconds > +# > +# Returns: Nothing on success > +# If key is unknown or redundant, QERR_INVALID_PARAMETER > +# If keys number is over the limitation, QERR_OVERFLOW > +# > +# Notes: Send keys to the emulator. Keys could be the name of the > +# key or the raw value in either decimal or hexadecimal format= =2E Use > +# "-" to press several keys simultaneously. These notes don't really correspond to the QMP interface of passing in a JSON array of simultaneous keys to press. > +# > +# Since: 0.14.0 Again, shouldn't this be 1.2? > +SQMP > +sendkey > +---------- > + > +Send keys to VM. > + > +Arguments: > + > +keys array: > + - "key": key sequence (json-string) > + > +- hold-time: time to delay key up events, miliseconds (josn-int, optio= nal) s/miliseconds/milliseconds/ --=20 Eric Blake eblake@redhat.com +1-919-301-3266 Libvirt virtualization library http://libvirt.org --------------enig0E82D45868DD727E75814C20 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.12 (GNU/Linux) Comment: Public key at http://people.redhat.com/eblake/eblake.gpg Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iQEcBAEBCAAGBQJPzOuxAAoJEKeha0olJ0NqNhsH/AlQFNBl9kUxGbbAaHAcAj7L 8zmACoNfb8jfRr89PKveXnZDZSUhFseFL2m1oqoVHnvOB+05/ZSxOpg+8ziCvlhp dy6enWOmCnIWeunqFYSq6rcCsuatjNuynlqsMCgApsP8KQUfaFg4+veqQIYjPUY1 hmhY3XSN5+XTT+c/EVynW8X4s2WvquDCHtcfpbZx6IM9Q9RXpXOGbI3tg4+X9onZ AzO4weEJonj6agfyETgjW1KasH0yvukRCAp0GVZ3OA25Gqpa2YaIcn8yZMXrNtE3 UaB+LHGgFAXHYFeoSSEe/T9mj6aatQdkuGjd7GjkGui/wRRKtW/rsluY8qgr1VY= =Mn9t -----END PGP SIGNATURE----- --------------enig0E82D45868DD727E75814C20--