<div dir="ltr">Yeah I'm not sure whether they should be merged either, I think it comes down to preference.  Maybe Vincent or Alexandre should decide.<div><br></div><div>About using the union in hardware_msg_data, you're right, I didn't notice that and I'll deduplicate that.</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, Jul 23, 2019 at 3:50 AM Rémi Bernon <<a href="mailto:rbernon@codeweavers.com">rbernon@codeweavers.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">On Sat, 2019-06-29 at 22:26 -0400, Derek Lesho wrote:<br>
> Signed-off-by: Derek Lesho <dereklesho52@Gmail.com><br>
> ---<br>
>  server/protocol.def | 28 ++++++++++++++++++++++++++++<br>
>  server/queue.c      | 41 +++++++++++++++++++++++++++++++++++++++++<br>
>  server/trace.c      | 21 +++++++++++++++++++++<br>
>  tools/make_requests |  1 +<br>
>  4 files changed, 91 insertions(+)<br>
> <br>
> diff --git a/server/protocol.def b/server/protocol.def<br>
> index 8b8a8a1512..3a6a202f49 100644<br>
> --- a/server/protocol.def<br>
> +++ b/server/protocol.def<br>
> @@ -358,6 +358,29 @@ typedef union<br>
>      } hw;<br>
>  } hw_input_t;<br>
>  <br>
> +typedef union<br>
> +{<br>
> +    int type;<br>
> +    struct<br>
> +    {<br>
> +        int type;                     /* RIM_TYPEMOUSE */<br>
> +        int x;                        /* relative x movement */<br>
> +        int y;                        /* relative y movement */<br>
> +        unsigned short button_flags;  /* mouse button */<br>
> +        unsigned short button_data;   /* event details */<br>
> +    } mouse;<br>
> +    struct<br>
> +    {<br>
> +        int type; /* RIM_TYPEKEYBOARD */<br>
> +        /* TODO: fill this in if/when necessary */<br>
> +    } kbd;<br>
> +    struct<br>
> +    {<br>
> +        int type; /* RIM_TYPEHID */<br>
> +        /* TODO: fill this in if/when necessary */<br>
> +    } hid;<br>
> +} hw_rawinput_t;<br>
<br>
I'm still wondering if it should be merged with hw_input_t or not and<br>
use the same send_hardware_message request for raw inputs and normal<br>
inputs, but in any case this union should at least be used for the<br>
rawinput field in struct hardware_msg_data (with the kbd fields added)<br>
instead of duplicating it.<br>
-- <br>
Rémi Bernon <<a href="mailto:rbernon@codeweavers.com" target="_blank">rbernon@codeweavers.com</a>><br>
<br>
<br>
<br>
</blockquote></div>