aboutsummaryrefslogtreecommitdiff
path: root/sway/desktop/xwayland.c
diff options
context:
space:
mode:
authoremersion <contact@emersion.fr>2018-04-06 11:27:40 -0400
committeremersion <contact@emersion.fr>2018-04-06 11:45:40 -0400
commit516f5454adb3fc7dd2e02258251b7cb6d6949aa3 (patch)
tree22c6bdfa1f79224daca6403162d24acdf611a6f9 /sway/desktop/xwayland.c
parentd447460c0153a76a0bc484bb9866cef658b3102f (diff)
Simplify damage tracking functions, use them in layer shell
Diffstat (limited to 'sway/desktop/xwayland.c')
-rw-r--r--sway/desktop/xwayland.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/sway/desktop/xwayland.c b/sway/desktop/xwayland.c
index 10bfcc89..6de1365d 100644
--- a/sway/desktop/xwayland.c
+++ b/sway/desktop/xwayland.c
@@ -32,15 +32,15 @@ static void unmanaged_handle_commit(struct wl_listener *listener, void *data) {
if (xsurface->x != surface->lx || xsurface->y != surface->ly) {
// Surface has moved
- desktop_damage_whole_surface(xsurface->surface,
- surface->lx, surface->ly);
+ desktop_damage_surface(xsurface->surface, surface->lx, surface->ly,
+ true);
surface->lx = xsurface->x;
surface->ly = xsurface->y;
- desktop_damage_whole_surface(xsurface->surface,
- surface->lx, surface->ly);
+ desktop_damage_surface(xsurface->surface, surface->lx, surface->ly,
+ true);
} else {
- desktop_damage_from_surface(xsurface->surface,
- xsurface->x, xsurface->y);
+ desktop_damage_surface(xsurface->surface, xsurface->x, xsurface->y,
+ false);
}
}
@@ -57,7 +57,7 @@ static void unmanaged_handle_map(struct wl_listener *listener, void *data) {
surface->lx = xsurface->x;
surface->ly = xsurface->y;
- desktop_damage_whole_surface(xsurface->surface, surface->lx, surface->ly);
+ desktop_damage_surface(xsurface->surface, surface->lx, surface->ly, true);
// TODO: we don't send surface enter/leave events to xwayland unmanaged
// surfaces, but xwayland doesn't support HiDPI anyway
@@ -67,7 +67,7 @@ static void unmanaged_handle_unmap(struct wl_listener *listener, void *data) {
struct sway_xwayland_unmanaged *surface =
wl_container_of(listener, surface, unmap);
struct wlr_xwayland_surface *xsurface = surface->wlr_xwayland_surface;
- desktop_damage_whole_surface(xsurface->surface, xsurface->x, xsurface->y);
+ desktop_damage_surface(xsurface->surface, xsurface->x, xsurface->y, true);
wl_list_remove(&surface->link);
wl_list_remove(&surface->commit.link);
}
@@ -209,7 +209,7 @@ static void handle_commit(struct wl_listener *listener, void *data) {
// TODO: Let floating views do whatever
view_update_size(view, xwayland_view->pending_width,
xwayland_view->pending_height);
- view_damage_from(view);
+ view_damage(view, false);
}
static void handle_unmap(struct wl_listener *listener, void *data) {