aboutsummaryrefslogtreecommitdiff
path: root/sway/tree/view.c
diff options
context:
space:
mode:
Diffstat (limited to 'sway/tree/view.c')
-rw-r--r--sway/tree/view.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/sway/tree/view.c b/sway/tree/view.c
index 6b4daa82..3ef79fa8 100644
--- a/sway/tree/view.c
+++ b/sway/tree/view.c
@@ -514,7 +514,7 @@ void view_map(struct sway_view *view, struct wlr_surface *wlr_surface) {
if (container_is_floating(focus)) {
focus = focus->parent->parent;
}
- free(criterias);
+ list_free(criterias);
cont = container_view_create(focus, view);
view->surface = wlr_surface;
@@ -574,6 +574,8 @@ void view_update_position(struct sway_view *view, double lx, double ly) {
container_damage_whole(view->swayc);
view->x = lx;
view->y = ly;
+ view->swayc->current.view_x = lx;
+ view->swayc->current.view_y = ly;
if (container_is_floating(view->swayc)) {
container_set_geometry_from_floating_view(view->swayc);
}
@@ -587,6 +589,8 @@ void view_update_size(struct sway_view *view, int width, int height) {
container_damage_whole(view->swayc);
view->width = width;
view->height = height;
+ view->swayc->current.view_width = width;
+ view->swayc->current.view_height = height;
if (container_is_floating(view->swayc)) {
container_set_geometry_from_floating_view(view->swayc);
}
@@ -919,7 +923,7 @@ static void update_marks_texture(struct sway_view *view,
double scale = output->sway_output->wlr_output->scale;
int width = 0;
- int height = config->font_height * scale;
+ int height = view->swayc->title_height * scale;
cairo_t *c = cairo_create(NULL);
get_text_size(c, config->font, &width, NULL, scale, false, "%s", buffer);