fix: resizing border on Linux WCO caption buttons (#43724)
Closes https://github.com/electron/electron/issues/43714. Fixes an issue where the resizing border was not being handled correctly on Linux WCO caption buttons. This is now taken into account as a part of the NonClientHitTest.
This commit is contained in:
		
					parent
					
						
							
								c1c8fbfd9a
							
						
					
				
			
			
				commit
				
					
						aa719a4066
					
				
			
		
					 1 changed files with 5 additions and 0 deletions
				
			
		| 
						 | 
					@ -135,6 +135,11 @@ gfx::Rect OpaqueFrameView::GetWindowBoundsForClientBounds(
 | 
				
			||||||
 | 
					
 | 
				
			||||||
int OpaqueFrameView::NonClientHitTest(const gfx::Point& point) {
 | 
					int OpaqueFrameView::NonClientHitTest(const gfx::Point& point) {
 | 
				
			||||||
  if (window()->IsWindowControlsOverlayEnabled()) {
 | 
					  if (window()->IsWindowControlsOverlayEnabled()) {
 | 
				
			||||||
 | 
					    // Ensure support for resizing frameless window with border drag.
 | 
				
			||||||
 | 
					    int frame_component = ResizingBorderHitTest(point);
 | 
				
			||||||
 | 
					    if (frame_component != HTNOWHERE)
 | 
				
			||||||
 | 
					      return frame_component;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    if (HitTestCaptionButton(close_button_, point))
 | 
					    if (HitTestCaptionButton(close_button_, point))
 | 
				
			||||||
      return HTCLOSE;
 | 
					      return HTCLOSE;
 | 
				
			||||||
    if (HitTestCaptionButton(restore_button_, point))
 | 
					    if (HitTestCaptionButton(restore_button_, point))
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue