You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Had two hours of "fun" bisecting, and it looks like we regressed back on 13 Nov 2019 in 07ae711 😱
Somewhat surprised this went unnoticed for so long... @Vino-Wang looks like we have a gap.
I still need to go through the diff (which is massive) to see what caused it.
🤔 Not sure what to look for tbh, @JeremyKuhne@weltkante if you have any hints - they are appreciated.
I took a quick look over Form.cs and what stands out regarding MDI forms is the removal of the "merged menu". Might have slipped up and left a bool or other variable in the wrong default state when removing the code. I might be able to debug later today.
this line is probably the regression. Can't seem to link directly for some reason, probably because the commit is so large? Its line 6081 in the diff of Form.cs in the commit linked above, I commented on the line but you have to manually scroll there. Within UpdateMenuHandles method an interop call for WM_MDISETMENU occurred even if no deprecated HMENU was configured by the user. I believe removing this interop call leads to the regression, because when I'm on a working build and skip this line I get the behavior you observe on master.
I think this can be fixed without reintroducing MainMenu and Menu classes, you just need to manufacture an appropriate HMENU directly via interop instead of using the WinForms convenience classes. Need to be careful to do proper cleanup though, to not introduce any leaks.
PS: I reviewed the diff of Form.cs manually against the release/3.1 branch and I think this is the only line which was removed even though it was executed. Also I'm quite confused by the commit being a merge of remote/release/3.1 yet the changes within the commit aren't in release/3.1. Was this a commit that was rolled back in 3.1 ?
I've started going through history again, and ran tests against 3.1.2, and it appears to be a regression all the way back to 3.1... So we'll need to service it.
he GetNativeMenuItemImageforgets to set the size of the struct (previously done in the constructor when it was still a class). All others in this PR do have the size assignment, its the only call where its missing.
Thank you, I started going mad at this point :)
I confirm the fix.
Verified the issue with latest 6.0 SDK 6.0.100-preview.1.21071.29 that the issue has been fixed, the MDI forms show sub control box correctly. see below screenshot.
Activity
RussKie commentedon Apr 2, 2020
Had two hours of "fun" bisecting, and it looks like we regressed back on 13 Nov 2019 in 07ae711 😱
Somewhat surprised this went unnoticed for so long... @Vino-Wang looks like we have a gap.
I still need to go through the diff (which is massive) to see what caused it.
🤔 Not sure what to look for tbh, @JeremyKuhne @weltkante if you have any hints - they are appreciated.
weltkante commentedon Apr 2, 2020
I took a quick look over Form.cs and what stands out regarding MDI forms is the removal of the "merged menu". Might have slipped up and left a bool or other variable in the wrong default state when removing the code. I might be able to debug later today.
Merge remote-tracking branch 'remote/release/3.1'
weltkante commentedon Apr 2, 2020
this line is probably the regression. Can't seem to link directly for some reason, probably because the commit is so large? Its line 6081 in the diff of Form.cs in the commit linked above, I commented on the line but you have to manually scroll there. Within
UpdateMenuHandlesmethod an interop call forWM_MDISETMENUoccurred even if no deprecated HMENU was configured by the user. I believe removing this interop call leads to the regression, because when I'm on a working build and skip this line I get the behavior you observe on master.I think this can be fixed without reintroducing
MainMenuandMenuclasses, you just need to manufacture an appropriateHMENUdirectly via interop instead of using the WinForms convenience classes. Need to be careful to do proper cleanup though, to not introduce any leaks.PS: I reviewed the diff of Form.cs manually against the
release/3.1branch and I think this is the only line which was removed even though it was executed. Also I'm quite confused by the commit being a merge ofremote/release/3.1yet the changes within the commit aren't inrelease/3.1. Was this a commit that was rolled back in 3.1 ?merriemcgaw commentedon Apr 2, 2020
Great investigation @weltkante! Thanks a ton!
RussKie commentedon Jun 16, 2020
I've started going through history again, and ran tests against 3.1.2, and it appears to be a regression all the way back to 3.1... So we'll need to service it.
33 remaining items
RussKie commentedon Jan 11, 2021
Thank you, I started going mad at this point :)
I confirm the fix.
fix MDI forms lost sub control box
Zheng-Li01 commentedon Jan 22, 2021
Verified the issue with latest 6.0 SDK 6.0.100-preview.1.21071.29 that the issue has been fixed, the MDI forms show sub control box correctly. see below screenshot.

Zheng-Li01 commentedon Jan 26, 2021
Verified the issue with 5.0.103-servicing.21073.8 that the issue has been fixed, the MDI forms show sub control box correctly.