This merge request implements the `httpapi.dll` `HttpResponseSendEntityBody` function and associated tests. API documentation was written by me by paraphrasing/re-writing what I had read for the function from the MSDN documentation. I am adding this function to enable the remote API component of the Space Engineers Dedicated Server.
Implementation notes:
- I mainly copied the relevant portion of `HttpSendHttpResponse` for `HttpResponseSendEntityBody`.
- I updated the `http_response` struct to add a field `response_flags`
- This field tracks the flags passed in to `HttpSendHttpResponse` and `HttpResponseSendEntityBody`.
- This was needed because the clean-up steps in `http.sys` need to be skipped when `HTTP_SEND_RESPONSE_FLAG_MORE_DATA` is set.
- I updated `HttpSendHttpResponse` to handle the `HTTP_SEND_RESPONSE_FLAG_MORE_DATA` flag by omitting the `Content-Length` header and setting the `response_flags` field in the `response` object passed to `http.sys`.
- The `Content-Length` header is omitted by the Windows implementation and thus I omitted it here for conformance purposes.
- I updated `http_send_response` in `http.sys` to skip the connection clean up steps if the `HTTP_SEND_RESPONSE_FLAG_MORE_DATA` flag was set. This works for both `HttpSendHttpResponse` and `HttpResponseSendEntityBody` as either could set the flag to continue to send more data.
- It is not 100% clear to me what the cleanup steps are doing. In particular, I am uncertain what lines 1011-1016 and 1023-1027 are doing, but based on context it seemed appropriate to keep them with the other connection cleanup steps.
For testing, I duplicated the existing `HttpSendHttpResponse` test but modified it to set the `HTTP_SEND_RESPONSE_FLAG_MORE_DATA` flag and then followed up with a call to `HttpResponseSendEntityBody` with new data. The validation ensures that data from both the initial response and follow up response are contained in the final response obtained via `recv()`. On Windows 11 this happens immediately without any delay, but in Wine I had to add a `Sleep(100)` to give enough time for the follow up response to be received in the socket buffer by the time the `recv()` call was made in the test. I could have looped the `recv()` call to collect all of the response, but that felt more complicated than adding a minor delay. The tests were verified against Windows 11 Pro (build 22621.3880).
--
v5: httpapi: Implement HttpSendResponseEntityBody
httpapi: Handle HTTP_SEND_RESPONSE_FLAG_MORE_DATA flag
http.sys: Skip clean up if HTTP_SEND_RESPONSE_FLAG_MORE_DATA is set
httpapi: Add tests for HttpResponseSendEntityBody
https://gitlab.winehq.org/wine/wine/-/merge_requests/6216
When the listview expands or collapses an item it notifies the parent using the TVN_ITEMEXPANDING message. The parent can return true on this message and it prevents the treeview from expanding or collapsing the item. WINE does not let you deny TVN_ITEMEXPANDING by returning true.
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=53727
--
v7: comctl32/treeview: Allow treeview parent to deny treeview expansion.
comctl32/tests: Add test to check if treeview expansion can be denied.
https://gitlab.winehq.org/wine/wine/-/merge_requests/6218
On Fri Aug 9 19:33:22 2024 +0000, Ilia Docin wrote:
> Sorry for the late response. Changed.
Not all of the comments are addressed.
Also, please add an 's' at the end of "comctl32/test" so it becomes "comctl32/tests: Add rebar chevron visibility test.".
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/6075#note_78420