mirror of
				https://github.com/swaywm/sway.git
				synced 2025-11-03 09:01:43 -05:00 
			
		
		
		
	Merge pull request #2100 from RyanDwyer/fix-workspace-orientation
Fix initial workspace orientation on a rotated output
This commit is contained in:
		
						commit
						4bc88772ec
					
				
					 1 changed files with 6 additions and 4 deletions
				
			
		| 
						 | 
				
			
			@ -8,10 +8,6 @@
 | 
			
		|||
 | 
			
		||||
struct sway_container *output_create(
 | 
			
		||||
		struct sway_output *sway_output) {
 | 
			
		||||
	struct wlr_box size;
 | 
			
		||||
	wlr_output_effective_resolution(sway_output->wlr_output, &size.width,
 | 
			
		||||
		&size.height);
 | 
			
		||||
 | 
			
		||||
	const char *name = sway_output->wlr_output->name;
 | 
			
		||||
	char identifier[128];
 | 
			
		||||
	output_get_identifier(identifier, sizeof(identifier), sway_output);
 | 
			
		||||
| 
						 | 
				
			
			@ -54,6 +50,12 @@ struct sway_container *output_create(
 | 
			
		|||
	container_add_child(&root_container, output);
 | 
			
		||||
	load_swaybars();
 | 
			
		||||
 | 
			
		||||
	struct wlr_box size;
 | 
			
		||||
	wlr_output_effective_resolution(sway_output->wlr_output, &size.width,
 | 
			
		||||
		&size.height);
 | 
			
		||||
	output->width = size.width;
 | 
			
		||||
	output->height = size.height;
 | 
			
		||||
 | 
			
		||||
	// Create workspace
 | 
			
		||||
	char *ws_name = workspace_next_name(output->name);
 | 
			
		||||
	wlr_log(L_DEBUG, "Creating default workspace %s", ws_name);
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue