Minimize Button Click Not Detected
See original GitHub issueOn some setups, clicking the in lower left corner of the minimize button on the title bar will not be detected correctly. The result from the hit test will come back with a 2 indicating the title bar rather than an 8 for the minimize button. For the WM_NCLBUTTONDOWN message, the WParam included in the Message passed to WndProc should be used to determine where the click occurred. https://msdn.microsoft.com/en-us/library/windows/desktop/ms645620(v=vs.85).aspx
This line should be removed and the relevant part of the if statement on the next line should be changed to
(uint)m.WParam == 2
Issue Analytics
- State:
- Created 6 years ago
- Reactions:1
- Comments:6 (2 by maintainers)
Top Results From Across the Web
FIX: Minimize/Maximize/Close Buttons Missing [Chrome, ...
Press Ctrl + Shift + Esc to start Task Manager. · When Task Manager opens, locate Desktop Windows Manager, right-click it, and choose...
Read more >Restore, Minimize, Maximize, Close buttons not working in ...
Turn off the Tablet Mode. Check in Clean Boot State. Reinstall the program. Run System File Checker. Run DISM. 1] Turn off the...
Read more >Cannot click taskbar or window minimize, maximize, and ...
1. Hit Ctrl + Alt + Del -> try several times clicing "Cancel" button. The everything back to normal. 2. Hit Win +...
Read more >minimize button not working : r/pop_os
simple solution for now, right click on title bar and minimize. Edit : Solution, disable pop-shell in extensions https://www.reddit.com/r/ ...
Read more >[SOLVED] How to detect a click on the minimize button
I suppose is not hard to do, but I'm struggling with this for a long time now :( I use KeyWait, LButton, D...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I think the better fix would be the one suggested by @TheBobman03. This would mean the dragging code works as it should too.
The suggested solution by @mapper55 will minimize the window as soon as the left mouse button is pressed down. This is not how Windows usually works; normally it’s only on mouseup that the action is taken.
That said, if you change it to look at WM_NCLBUTTONUP instead, then clicking in the red region initiates a drag operation, whereas minimizing on mousedown doesn’t give time for that. The proper fix would be to use the correct hit test value for the drag operation too.