mirror of
				https://gitlab.freedesktop.org/wlroots/wlroots.git
				synced 2025-11-03 09:01:40 -05:00 
			
		
		
		
	subsurface: rename wlr_subsurface_state to wlr_subsurface_parent_state
Add a comment to explain the difference.
This commit is contained in:
		
							parent
							
								
									242c23743f
								
							
						
					
					
						commit
						56b6b80b9a
					
				
					 2 changed files with 9 additions and 4 deletions
				
			
		| 
						 | 
					@ -163,7 +163,12 @@ struct wlr_surface {
 | 
				
			||||||
	} previous;
 | 
						} previous;
 | 
				
			||||||
};
 | 
					};
 | 
				
			||||||
 | 
					
 | 
				
			||||||
struct wlr_subsurface_state {
 | 
					/**
 | 
				
			||||||
 | 
					 * The sub-surface state describing the sub-surface's relationship with its
 | 
				
			||||||
 | 
					 * parent. Contrary to other states, this one is not applied on surface commit.
 | 
				
			||||||
 | 
					 * Instead, it's applied on parent surface commit.
 | 
				
			||||||
 | 
					 */
 | 
				
			||||||
 | 
					struct wlr_subsurface_parent_state {
 | 
				
			||||||
	int32_t x, y;
 | 
						int32_t x, y;
 | 
				
			||||||
};
 | 
					};
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					@ -172,7 +177,7 @@ struct wlr_subsurface {
 | 
				
			||||||
	struct wlr_surface *surface;
 | 
						struct wlr_surface *surface;
 | 
				
			||||||
	struct wlr_surface *parent;
 | 
						struct wlr_surface *parent;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	struct wlr_subsurface_state current, pending;
 | 
						struct wlr_subsurface_parent_state current, pending;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	uint32_t cached_seq;
 | 
						uint32_t cached_seq;
 | 
				
			||||||
	bool has_cache;
 | 
						bool has_cache;
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -1350,7 +1350,7 @@ static void surface_for_each_surface(struct wlr_surface *surface, int x, int y,
 | 
				
			||||||
		wlr_surface_iterator_func_t iterator, void *user_data) {
 | 
							wlr_surface_iterator_func_t iterator, void *user_data) {
 | 
				
			||||||
	struct wlr_subsurface *subsurface;
 | 
						struct wlr_subsurface *subsurface;
 | 
				
			||||||
	wl_list_for_each(subsurface, &surface->subsurfaces_below, parent_link) {
 | 
						wl_list_for_each(subsurface, &surface->subsurfaces_below, parent_link) {
 | 
				
			||||||
		struct wlr_subsurface_state *state = &subsurface->current;
 | 
							struct wlr_subsurface_parent_state *state = &subsurface->current;
 | 
				
			||||||
		int sx = state->x;
 | 
							int sx = state->x;
 | 
				
			||||||
		int sy = state->y;
 | 
							int sy = state->y;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					@ -1361,7 +1361,7 @@ static void surface_for_each_surface(struct wlr_surface *surface, int x, int y,
 | 
				
			||||||
	iterator(surface, x, y, user_data);
 | 
						iterator(surface, x, y, user_data);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	wl_list_for_each(subsurface, &surface->subsurfaces_above, parent_link) {
 | 
						wl_list_for_each(subsurface, &surface->subsurfaces_above, parent_link) {
 | 
				
			||||||
		struct wlr_subsurface_state *state = &subsurface->current;
 | 
							struct wlr_subsurface_parent_state *state = &subsurface->current;
 | 
				
			||||||
		int sx = state->x;
 | 
							int sx = state->x;
 | 
				
			||||||
		int sy = state->y;
 | 
							int sy = state->y;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue