qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH] add input-send-event command


From: Eric Blake
Subject: Re: [Qemu-devel] [PATCH] add input-send-event command
Date: Tue, 17 Jun 2014 05:54:35 -0600
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.6.0

On 06/17/2014 03:02 AM, Gerd Hoffmann wrote:
> On Mo, 2014-06-16 at 20:15 -0300, Marcelo Tosatti wrote:
>> Which allows specification of absolute/relative, 
>> up/down and console parameters.
> 
> Looks good overall, only minor nits.  Will wait for acks from qmp guys
> before picking into input branch.
> 
>> Suggested by Gerd Hoffman.
> 
> Huh?  Signed-off missing ...
> 
>> +Press left mouse button.
>> +
>> +-> { "execute": "input-send-event",
>> +    "arguments": { "console": 0,
>> +                   "events": [ { "type": "btn",
>> +                    "data" : { "down": true, "button": "Left" } },
>> +                    { "type": "btn",
>> +                      "data" : { "down": false, "button": "Left" } } ] } }
>> +<- { "return": {} }
> 
> Bad example.  Down + up should go as separate commands (so you have a
> sync inbetween), otherwise it might happen that the guest doesn't see
> the button event at all.

Would it be worth adding a command to the union of possible events that
adds a pause?  As in:

-> { "execute": "input-send-event",
    "arguments": { "console": 0,
                   "events": [
                    { "type": "btn",
                      "data" : { "down": true, "button": "Left" } },
                    { "type": "pause", "data": { "duration": 10 } },
                    { "type": "btn",
                      "data" : { "down": false, "button": "Left" } } ] } }

that sticks a 10 ms delay between the other two events?

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]