mirror of
				https://gitlab.freedesktop.org/wlroots/wlroots.git
				synced 2025-11-03 09:01:40 -05:00 
			
		
		
		
	Minor nitpicking in wl_compositor
This commit is contained in:
		
							parent
							
								
									de17ce19be
								
							
						
					
					
						commit
						95653c0bf7
					
				
					 1 changed files with 3 additions and 9 deletions
				
			
		| 
						 | 
					@ -87,19 +87,13 @@ static void destroy_surface_listener(struct wl_listener *listener, void *data) {
 | 
				
			||||||
	struct wlr_surface *surface = data;
 | 
						struct wlr_surface *surface = data;
 | 
				
			||||||
	state = wl_container_of(listener, state, destroy_surface_listener);
 | 
						state = wl_container_of(listener, state, destroy_surface_listener);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	struct wl_resource *res = NULL, *_res;
 | 
						struct wl_resource *res = NULL;
 | 
				
			||||||
	wl_list_for_each(_res, &state->surfaces, link) {
 | 
						wl_list_for_each(res, &state->surfaces, link) {
 | 
				
			||||||
		if (_res == surface->resource) {
 | 
							if (_res == surface->resource) {
 | 
				
			||||||
			res = _res;
 | 
								wl_list_remove(&res->link);
 | 
				
			||||||
			break;
 | 
								break;
 | 
				
			||||||
		}
 | 
							}
 | 
				
			||||||
	}
 | 
						}
 | 
				
			||||||
 | 
					 | 
				
			||||||
	if (!res) {
 | 
					 | 
				
			||||||
		return;
 | 
					 | 
				
			||||||
	}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
	wl_list_remove(&res->link);
 | 
					 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
static void wl_compositor_create_surface(struct wl_client *client,
 | 
					static void wl_compositor_create_surface(struct wl_client *client,
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue