i) Introduce a helper for calculating transform properties.
ii) Re-use get_log_fontW to populate LOGFONTW from GpFont.
Signed-off-by: David Kahurani k.kahurani(a)gmail.com
--
v4: gdiplus: Use get_log_fontW in GdipGetLogFontW
gdiplus: Use helper to calculate transform properties
https://gitlab.winehq.org/wine/wine/-/merge_requests/3471
1. Subtracting integers may result in an overflow or underflow.
2. Right at the 'edge' of underflowing, the result of subtraction may be
`INT_MIN`, and the call to `abs()` will also result in `INT_MIN`.
This fix accounts for all of these conditions.
EXAMPLES:
1. can be encountered by comparing 2.0 and -2.0
2. can be encountered by comparing -2.0 and 2.0
NOTE:
There are 14 more instances of `compare_float` across several modules.
I would like to make sure the logic is sound with this MR, then I can take on the rest.
--
v3: ddraw/tests: Fix overflow bugs in compare_float.
https://gitlab.winehq.org/wine/wine/-/merge_requests/3458
This is first part in a series that implements Cycle Collection for every mshtml object (dispex) and cleans up rest of the code based on it, which is obviously needed due to dynamic props and other extra object-specific refs.
In an effort to split it up as much as possible, since it already has quite a lot of restructuring and changes, some of the earlier patches will introduce temporary leaks or cyclic refs, but that's because we'll later handle them properly with the dispex CC. These shouldn't affect behavior, though, so it shouldn't pose problems for functionality.
Nodes are, initially, not changed much (other than to make it compatible with the dispex) to keep changes as small as possible. They still use their own CC mechanism and refcounting, which is hackish but that is solved in a follow-up MR, so it's temporary only.
Eventually, every object (including nodes) will use the dispex's vtbl to do its Cycle Collection, except for stuff like outer window (which is a special case).
In this first part, the objects that are using the node CC will have no-op dispex CC methods since they are using the node's, but this is temporary only.
v2: Now the entire first part will be split up into several MRs. This only moves destruction/unlinking of dispex into separate vtbl methods, without actually using any of the CC yet. `release_dispex` will now call the unlink and destructor, if available (it won't be optional later, but for now it is), so only those converted objects make use of it.
Most of the patches are small and typically convert one object at a time, except the first 4. More will follow up in subsequent MRs.
--
v3: mshtml: Use unlink and destructor in the vtbl for the MutationObserver
mshtml: Use unlink and destructor in the vtbl for HTMLXMLHttpRequestFactory.
mshtml: Use unlink and destructor in the vtbl for HTMLOptionElementFactory.
mshtml: Use unlink and destructor in the vtbl for HTMLImageElementFactory.
mshtml: Use unlink and destructor in the vtbl for HTMLStyleSheet.
mshtml: Use unlink and destructor in the vtbl for HTMLStyleSheetsCollection.
mshtml: Use unlink and destructor in the vtbl for
mshtml: Use unlink and destructor in the vtbl for HTMLStyleSheetRule.
mshtml: Use unlink and destructor in the vtbl for CSSStyle.
mshtml: Use unlink and destructor in the vtbl for inner windows.
mshtml: Use unlink and destructor in the vtbl for HTMLEventObj.
mshtml: Use separate dispex destructors for different event types.
mshtml: Use unlink and destructor in the vtbl for function disps.
mshtml: Introduce unlink_ref helper.
mshtml: Use the common HTMLElement dispex vtbl in the dispex definitions.
https://gitlab.winehq.org/wine/wine/-/merge_requests/3408
This is first part in a series that implements Cycle Collection for every mshtml object (dispex) and cleans up rest of the code based on it, which is obviously needed due to dynamic props and other extra object-specific refs.
In an effort to split it up as much as possible, since it already has quite a lot of restructuring and changes, some of the earlier patches will introduce temporary leaks or cyclic refs, but that's because we'll later handle them properly with the dispex CC. These shouldn't affect behavior, though, so it shouldn't pose problems for functionality.
Nodes are, initially, not changed much (other than to make it compatible with the dispex) to keep changes as small as possible. They still use their own CC mechanism and refcounting, which is hackish but that is solved in a follow-up MR, so it's temporary only.
Eventually, every object (including nodes) will use the dispex's vtbl to do its Cycle Collection, except for stuff like outer window (which is a special case).
In this first part, the objects that are using the node CC will have no-op dispex CC methods since they are using the node's, but this is temporary only.
v2: Now the entire first part will be split up into several MRs. This only moves destruction/unlinking of dispex into separate vtbl methods, without actually using any of the CC yet. `release_dispex` will now call the unlink and destructor, if available (it won't be optional later, but for now it is), so only those converted objects make use of it.
Most of the patches are small and typically convert one object at a time, except the first 4. More will follow up in subsequent MRs.
--
v2: mshtml: Use unlink and destructor in the vtbl for the MutationObserver
mshtml: Use unlink and destructor in the vtbl for HTMLXMLHttpRequestFactory.
mshtml: Use unlink and destructor in the vtbl for HTMLOptionElementFactory.
mshtml: Use unlink and destructor in the vtbl for HTMLImageElementFactory.
mshtml: Use unlink and destructor in the vtbl for HTMLStyleSheet.
mshtml: Use unlink and destructor in the vtbl for HTMLStyleSheetsCollection.
mshtml: Use unlink and destructor in the vtbl for
mshtml: Use unlink and destructor in the vtbl for HTMLStyleSheetRule.
mshtml: Use unlink and destructor in the vtbl for CSSStyle.
mshtml: Use unlink and destructor in the vtbl for inner windows.
mshtml: Use unlink and destructor in the vtbl for HTMLEventObj.
mshtml: Use separate dispex destructors for different event types.
mshtml: Use unlink and destructor in the vtbl for function disps.
mshtml: Introduce unlink_ref helper.
mshtml: Use the common HTMLElement dispex vtbl in the dispex definitions.
https://gitlab.winehq.org/wine/wine/-/merge_requests/3408
Particularly it implements '/upn', '/logonid' and '/user' options,
where the first one uses newly added NameUserPrincipal format in GetUserNameExW.
--
v2: whoami: Refactor and add more commands.
https://gitlab.winehq.org/wine/wine/-/merge_requests/3473
i) Introduce a helper for calculating transform properties.
ii) Re-use get_log_fontW to populate LOGFONTW from GpFont.
Signed-off-by: David Kahurani k.kahurani(a)gmail.com
--
v2: gdiplus: Use get_log_fontW in GdipGetLogFontW
gdiplus: Use helper to calculate transform properties
https://gitlab.winehq.org/wine/wine/-/merge_requests/3471
i) Introduce a helper for calculating transform properties.
ii) Re-use get_log_fontW to populate LOGFONTW from GpFont.
Signed-off-by: David Kahurani k.kahurani(a)gmail.com
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/3471