[prev in list] [next in list] [prev in thread] [next in thread]
List: wine-devel
Subject: Re: [PATCH v2 2/6] dlls/kernelbase, programs/conhost: return key state in ReadConsoleW with control
From: Eric Pouech <eric.pouech () orange ! fr>
Date: 2022-02-28 16:23:49
Message-ID: a8ff4176-f236-4007-e42e-28541b3987c0 () orange ! fr
[Download RAW message or body]
Le 28/02/2022 à 16:50, Jacek Caban a écrit :
> On 2/27/22 15:23, Eric Pouech wrote:
>> Le 25/02/2022 à 20:19, Jacek Caban a écrit :
>>> On 2/23/22 18:05, Eric Pouech wrote:
>>>> diff --git a/programs/conhost/conhost.h b/programs/conhost/conhost.h
>>>> index e5f70aa3ca4..35876689419 100644
>>>> --- a/programs/conhost/conhost.h
>>>> +++ b/programs/conhost/conhost.h
>>>> @@ -88,6 +88,7 @@ struct console
>>>> unsigned int read_ioctl; /* current read
>>>> ioctl */
>>>> size_t pending_read; /* size of
>>>> pending read buffer */
>>>> struct edit_line edit_line; /* edit line
>>>> context */
>>>> + unsigned int key_state;
>>>> struct console_window *window;
>>>> WCHAR *title; /* console title */
>>>> struct history_line **history; /* lines history */
>>>
>>>
>>> I think it would fit better in edit_line struct.
>>
>>
>> as the edit struct is zeroed upon completion (and before returning
>> the result), it would also require moving
>>
>> - write of the key state inside the edit buffer in
>> process_console_input() (insert 2 new characters for the DWORD)
>>
>> - hence handle in process_console_input that the layout of the buffer
>> differs depending on ioctl
>>
>> I thought it was more readable to keep the edit logic as is, and and
>> on top of it returning or not the keystate flag
>>
>> but see no reason why it wouldn't be doable
>
>
> Agreed, it's probably not worth the complication. That's fine with me.
>
>
> Thanks,
>
> Jacek
>
ok I'll resend with the fix on the delta_y inversion (likely tomorrow
depending on what Alexandre commits or not tonight)
A+
[Attachment #3 (text/html)]
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
</head>
<body>
<div class="moz-cite-prefix">Le 28/02/2022 à 16:50, Jacek Caban a
écrit :<br>
</div>
<blockquote type="cite"
cite="mid:c7d42d67-7343-1034-d9c6-b2c49ab6ab8e@codeweavers.com">On
2/27/22 15:23, Eric Pouech wrote:
<br>
<blockquote type="cite">Le 25/02/2022 à 20:19, Jacek Caban a
écrit :
<br>
<blockquote type="cite">On 2/23/22 18:05, Eric Pouech wrote:
<br>
<blockquote type="cite">diff --git
a/programs/conhost/conhost.h b/programs/conhost/conhost.h
<br>
index e5f70aa3ca4..35876689419 100644
<br>
--- a/programs/conhost/conhost.h
<br>
+++ b/programs/conhost/conhost.h
<br>
@@ -88,6 +88,7 @@ struct console
<br>
unsigned int read_ioctl; /* current
read ioctl */
<br>
size_t pending_read; /* size of
pending read buffer */
<br>
struct edit_line edit_line; /* edit
line context */
<br>
+ unsigned int key_state;
<br>
struct console_window *window;
<br>
WCHAR *title; /* console
title */
<br>
struct history_line **history; /* lines
history */
<br>
</blockquote>
<br>
<br>
I think it would fit better in edit_line struct.
<br>
</blockquote>
<br>
<br>
as the edit struct is zeroed upon completion (and before
returning the result), it would also require moving
<br>
<br>
- write of the key state inside the edit buffer in
process_console_input() (insert 2 new characters for the DWORD)
<br>
<br>
- hence handle in process_console_input that the layout of the
buffer differs depending on ioctl
<br>
<br>
I thought it was more readable to keep the edit logic as is, and
and on top of it returning or not the keystate flag
<br>
<br>
but see no reason why it wouldn't be doable
<br>
</blockquote>
<br>
<br>
Agreed, it's probably not worth the complication. That's fine with
me.
<br>
<br>
<br>
Thanks,
<br>
<br>
Jacek
<br>
<br>
</blockquote>
<p><font face="Helvetica, Arial, sans-serif">ok I'll resend with the
fix on the delta_y inversion (likely tomorrow depending on what
Alexandre commits or not tonight)</font></p>
<p><font face="Helvetica, Arial, sans-serif">A+</font><br>
</p>
</body>
</html>
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic