diff options
author | emersion <contact@emersion.fr> | 2018-05-31 12:33:27 +0100 |
---|---|---|
committer | emersion <contact@emersion.fr> | 2018-05-31 12:33:27 +0100 |
commit | 21928cbe615184a81d157ccc68e503282efff83c (patch) | |
tree | e2523e48aadc69a109909ee37af18c76d88e4859 /rootston/xdg_shell.c | |
parent | c844eaa1b32894417263ce2b5030033bdd7c7851 (diff) | |
parent | 32013abae63f1c31598ac716acd7e73c24fadae1 (diff) |
Merge branch 'master' into screencontent
Diffstat (limited to 'rootston/xdg_shell.c')
-rw-r--r-- | rootston/xdg_shell.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/rootston/xdg_shell.c b/rootston/xdg_shell.c index 83a1caf0..03ae1dc6 100644 --- a/rootston/xdg_shell.c +++ b/rootston/xdg_shell.c @@ -135,11 +135,10 @@ static void get_size(const struct roots_view *view, struct wlr_box *box) { if (surface->geometry.width > 0 && surface->geometry.height > 0) { box->width = surface->geometry.width; box->height = surface->geometry.height; - } else if (view->wlr_surface != NULL) { - box->width = view->wlr_surface->current->width; - box->height = view->wlr_surface->current->height; } else { - box->width = box->height = 0; + assert(surface->surface); + box->width = surface->surface->current->width; + box->height = surface->surface->current->height; } } |