mirror of
				https://gitlab.freedesktop.org/wlroots/wlroots.git
				synced 2025-11-03 09:01:40 -05:00 
			
		
		
		
	Fix centering views on scaled outputs
This commit is contained in:
		
							parent
							
								
									75fd9b8426
								
							
						
					
					
						commit
						aafb00a15f
					
				
					 1 changed files with 0 additions and 2 deletions
				
			
		| 
						 | 
					@ -136,8 +136,6 @@ bool view_center(struct roots_view *view) {
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	int width, height;
 | 
						int width, height;
 | 
				
			||||||
	wlr_output_effective_resolution(output, &width, &height);
 | 
						wlr_output_effective_resolution(output, &width, &height);
 | 
				
			||||||
	width /= output->scale;
 | 
					 | 
				
			||||||
	height /= output->scale;
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
	double view_x = (double)(width - box.width) / 2 + l_output->x;
 | 
						double view_x = (double)(width - box.width) / 2 + l_output->x;
 | 
				
			||||||
	double view_y = (double)(height - box.height) / 2 + l_output->y;
 | 
						double view_y = (double)(height - box.height) / 2 + l_output->y;
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue