Do not call wlr_surface_state_release_buffer anymore

This commit is contained in:
emersion 2017-10-11 20:29:21 +02:00
parent 67f0c3ca42
commit 5c6a933890
No known key found for this signature in database
GPG Key ID: 0FDE7BE0E88F5E48
2 changed files with 5 additions and 6 deletions

View File

@ -238,10 +238,6 @@ void wlr_output_set_cursor_surface(struct wlr_output *output,
output->cursor.hotspot_x = hotspot_x; output->cursor.hotspot_x = hotspot_x;
output->cursor.hotspot_y = hotspot_y; output->cursor.hotspot_y = hotspot_y;
if (surface && output->cursor.surface == surface) {
return;
}
if (output->cursor.surface) { if (output->cursor.surface) {
wl_list_remove(&output->cursor.surface_commit.link); wl_list_remove(&output->cursor.surface_commit.link);
wl_list_remove(&output->cursor.surface_destroy.link); wl_list_remove(&output->cursor.surface_destroy.link);
@ -252,7 +248,9 @@ void wlr_output_set_cursor_surface(struct wlr_output *output,
if (surface != NULL) { if (surface != NULL) {
wl_signal_add(&surface->events.commit, &output->cursor.surface_commit); wl_signal_add(&surface->events.commit, &output->cursor.surface_commit);
wl_signal_add(&surface->events.destroy, &output->cursor.surface_destroy); wl_signal_add(&surface->events.destroy,
&output->cursor.surface_destroy);
commit_cursor_surface(output, surface);
} else { } else {
set_cursor(output, NULL, 0, 0, 0, hotspot_x, hotspot_y); set_cursor(output, NULL, 0, 0, 0, hotspot_x, hotspot_y);
} }

View File

@ -427,7 +427,8 @@ static void wlr_surface_commit_pending(struct wlr_surface *surface) {
// TODO: add the invalid bitfield to this callback // TODO: add the invalid bitfield to this callback
wl_signal_emit(&surface->events.commit, surface); wl_signal_emit(&surface->events.commit, surface);
wlr_surface_state_release_buffer(surface->current); // TODO: call this
//wlr_surface_state_release_buffer(surface->current);
} }
static bool wlr_subsurface_is_synchronized(struct wlr_subsurface *subsurface) { static bool wlr_subsurface_is_synchronized(struct wlr_subsurface *subsurface) {